{"version":3,"sources":["webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/ascending.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/bisector.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/number.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/bisect.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/fsum.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/array.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/ticks.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/median.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/merge.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/permute.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/range.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/shuffle.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/math.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/noop.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/stream.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/area.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/bounds.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/cartesian.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/centroid.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/constant.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/compose.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/rotation.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/circle.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/buffer.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/pointEqual.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/rejoin.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/polygonContains.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/index.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/antimeridian.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/circle.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/line.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/rectangle.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/extent.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/length.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/distance.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/contains.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/graticule.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/interpolate.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/area.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/identity.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/bounds.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/centroid.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/context.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/measure.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/string.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/index.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/transform.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/fit.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/resample.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/index.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conicEqualArea.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/cylindricalEqualArea.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/albers.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/albersUsa.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/azimuthal.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/azimuthalEqualArea.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/azimuthalEquidistant.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/mercator.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conicConformal.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/equirectangular.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conicEquidistant.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/equalEarth.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/gnomonic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/identity.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/naturalEarth1.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/orthographic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/stereographic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/transverseMercator.js","webpack:///../../../../../src/.internal/charts/map/MapSeries.ts","webpack:///../../../../../src/.internal/charts/map/MapObject.ts","webpack:///../../../../../src/.internal/charts/map/MapImage.ts","webpack:///../../../../../src/.internal/charts/map/MapUtils.ts","webpack:///../../../../../src/.internal/charts/map/MapPolygon.ts","webpack:///../../../../../src/.internal/charts/map/MapPolygonSeries.ts","webpack:///../../../../../../src/.internal/charts/map/projections/Projection.ts","webpack:///../../../../../src/.internal/charts/map/SmallMap.ts","webpack:///../../../../../src/.internal/charts/map/Geo.ts","webpack:///../../../../../src/.internal/charts/map/MapLineObject.ts","webpack:///../../../../../src/.internal/charts/map/MapImageSeries.ts","webpack:///../../../../../src/.internal/charts/map/MapLine.ts","webpack:///../../../../../src/.internal/charts/map/MapLineSeries.ts","webpack:///../../../../../src/.internal/charts/map/Graticule.ts","webpack:///../../../../../src/.internal/charts/map/GraticuleSeries.ts","webpack:///../../../../../src/.internal/charts/types/MapChart.ts","webpack:///../../../../../src/.internal/charts/map/MapSpline.ts","webpack:///../../../../../src/.internal/charts/map/MapArc.ts","webpack:///../../../../../src/.internal/charts/map/MapSplineSeries.ts","webpack:///../../../../../src/.internal/charts/map/MapArcSeries.ts","webpack:///../../../../../src/.internal/charts/map/ZoomControl.ts","webpack:///../../../../../../src/.internal/charts/map/projections/Mercator.ts","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/math.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/aitoff.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/august.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/baker.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/hammer.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/newton.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mollweide.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/boggs.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/sinusoidal.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/bromley.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/collignon.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/craig.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/craster.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/cylindricalEqualArea.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert1.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert2.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert3.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert4.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert5.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert6.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eisenlohr.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/fahey.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/foucaut.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/gingery.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburgPolyconic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg4.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg5.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg6.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg8.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg9.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/gringorten.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/elliptic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/guyou.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/healpix.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/hill.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/sinuMollweide.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/homolosine.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/kavrayskiy7.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/lagrange.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/larrivee.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/laskowski.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/littrow.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/miller.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mtFlatPolarParabolic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mtFlatPolarQuartic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mtFlatPolarSinusoidal.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/naturalEarth2.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/nellHammer.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/nicolosi.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/patterson.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/polyconic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/polyhedral/octahedron.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/polyhedral/collignon.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/rectangularPolyconic.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/robinson.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/times.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten2.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten3.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten4.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/wagner4.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/wagner6.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/wiechel.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/winkel3.js","webpack:///../../../../../../src/.internal/charts/map/projections/Miller.ts","webpack:///../../../../../../src/.internal/charts/map/projections/Eckert6.ts","webpack:///../../../../../../src/.internal/charts/map/projections/Orthographic.ts","webpack:///../../../../../../src/.internal/charts/map/projections/Stereographic.ts","webpack:///../../../../../../src/.internal/charts/map/projections/Albers.ts","webpack:///../../../../../../src/.internal/charts/map/projections/AlbersUsa.ts","webpack:///../../../../../../src/.internal/charts/map/projections/NaturalEarth1.ts","webpack:///../../../../../../src/.internal/charts/map/projections/AzimuthalEqualArea.ts","webpack:///../../../../../../src/.internal/charts/map/projections/EqualEarth.ts","webpack:///./maps.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/tinyqueue/index.js","webpack:///C:/Dropbox/www/amcharts4dev/node_modules/polylabel/polylabel.js"],"names":["ascending","a","b","NaN","bisector","f","delta","compare","left","x","lo","hi","length","mid","d","ascendingComparator","center","i","right","number","ascendingBisect","Adder","_classCallCheck","this","_partials","Float64Array","_n","_createClass","key","value","p","j","y","Math","abs","n","array","Array","prototype","slice","map","sqrt","flatten","arrays","_iterator","_step","regeneratorRuntime","wrap","_context","prev","next","merge__createForOfIteratorHelper","s","done","delegateYield","t1","e","finish","stop","merge__marked","merge","from","range","start","step","arguments","max","ceil","random","epsilon","epsilon2","pi","PI","halfPi","quarterPi","tau","degrees","radians","atan","atan2","cos","exp","hypot","floor","log","pow","sin","sign","tan","acos","asin","haversin","noop","streamGeometry","geometry","stream","streamGeometryType","hasOwnProperty","type","streamObjectType","Feature","object","FeatureCollection","features","Sphere","sphere","Point","coordinates","point","MultiPoint","LineString","streamLine","MultiLineString","Polygon","streamPolygon","MultiPolygon","GeometryCollection","geometries","closed","coordinate","lineStart","lineEnd","polygonStart","polygonEnd","lambda00","phi00","lambda0","cosPhi0","sinPhi0","src_stream","areaRingSum","areaSum","areaStream","areaRingStart","areaRingEnd","areaRing","add","areaPointFirst","areaPoint","lambda","phi","dLambda","sdLambda","adLambda","cosPhi","sinPhi","k","u","v","phi0","lambda1","phi1","lambda2","p0","deltaSum","ranges","src_area","spherical","cartesian","cartesianDot","cartesianCross","cartesianAddInPlace","cartesianScale","vector","cartesianNormalizeInPlace","l","boundsStream","boundsPoint","boundsLineStart","boundsLineEnd","boundsRingPoint","boundsRingStart","boundsRingEnd","push","linePoint","normal","inflection","phii","lambdai","antimeridian","angle","rangeCompare","rangeContains","W0","W1","X0","Y0","Z0","X1","Y1","Z1","X2","Y2","Z2","x0","y0","z0","src_bounds","feature","merged","deltaMax","Infinity","sort","centroidStream","centroidPoint","centroidLineStart","centroidLineEnd","centroidRingStart","centroidRingEnd","centroidPointCartesian","z","centroidLinePointFirst","centroidLinePoint","w","centroidRingPointFirst","centroidRingPoint","cx","cy","cz","m","centroid","src_constant","compose","invert","rotationIdentity","round","rotateRadians","deltaLambda","deltaPhi","deltaGamma","rotationLambda","rotationPhiGamma","forwardRotationLambda","rotation","cosDeltaPhi","sinDeltaPhi","cosDeltaGamma","sinDeltaGamma","src_rotation","rotate","forward","circleStream","radius","direction","t0","cosRadius","sinRadius","circleRadius","t","src_circle","ring","constant","precision","circle","c","apply","r","_","buffer","line","lines","rejoin","pop","concat","shift","result","pointEqual","Intersection","points","other","entry","o","segments","compareIntersection","startInside","interpolate","subject","clip","forEach","segment","p1","link","current","isSubject","longitude","polygonContains","polygon","winding","sum","point0","sinPhi1","cosPhi1","point1","absDelta","arc","intersection","phiArc","src_clip","pointVisible","clipLine","sink","ringBuffer","clipBuffer","ringSink","polygonStarted","pointRing","ringStart","ringEnd","clipRejoin","pointLine","clean","ringSegments","filter","validSegment","sign0","sign1","sinLambda0Lambda1","clipAntimeridianIntersect","to","clip_circle","cr","smallRadius","notHemisphere","visible","intersect","two","n1","n2","n2n2","n1n2","determinant","c1","c2","n1xn2","A","uu","t2","q","polar","q1","code","c0","v0","v00","point2","clip_line","x1","y1","ax","ay","dx","dy","clipMax","clipMin","clipRectangle","a1","corner","comparePoint","ca","cb","x__","y__","v__","x_","y_","v_","first","activeStream","bufferStream","clipStream","a0","b0","b1","polygonInside","cleanInside","min","lengthSum","clip_extent","cache","cacheStream","extent","lengthStream","lengthPointFirst","lengthLineEnd","lengthPoint","cosDelta","src_length","src_distance","containsObjectType","containsGeometry","containsGeometryType","containsPoint","containsLine","containsPolygon","distance","ao","bo","ab","ringRadians","pointRadians","contains","graticuleX","graticuleY","graticule","X","Y","DX","DY","outline","reverse","extentMajor","extentMinor","stepMajor","stepMinor","graticule10","x00","y00","src_interpolate","cy0","sy0","cy1","sy1","kx0","ky0","kx1","ky1","B","src_identity","area","bounds","centroidPointFirstLine","centroidPointLine","centroidPointFirstRing","centroidPointRing","PathContext","context","_radius","pointRadius","_line","_point","closePath","moveTo","lineTo","lengthRing","PathString","_string","_circle","join","src_path","projection","projectionStream","contextStream","path","pathArea","measure","pathMeasure","pathBounds","pathCentroid","identity","src_transform","methods","transformer","TransformStream","fit","fitBounds","clipExtent","scale","translate","geoStream","fitExtent","h","fitSize","size","fitWidth","width","fitHeight","height","constructor","maxDepth","cosMinDistance","resample","project","delta2","resampleLineTo","depth","d2","phi2","x2","y2","dx2","dy2","dz","a00","b00","c00","resampleStream","ringPoint","resampleNone","transformRadians","scaleTranslateRotate","sx","sy","alpha","transform","scaleTranslate","cosAlpha","sinAlpha","ai","bi","ci","fi","projectionMutator","projectAt","projectResample","projectTransform","projectRotateTransform","theta","preclip","clipAntimeridian","postclip","recenter","reset","transformRotate","undefined","clipAngle","clipCircle","reflectX","reflectY","conicProjection","parallels","conicEqualAreaRaw","cylindricalEqualAreaRaw","r0","r0y","conicEqualArea","albers","projection_albersUsa","lower48Point","alaskaPoint","hawaiiPoint","lower48","alaska","hawaii","pointStream","albersUsa","streams","multiplex","azimuthalRaw","azimuthalInvert","sc","cc","azimuthalEqualAreaRaw","cxcy","azimuthalEqualArea","azimuthalEquidistantRaw","azimuthalEquidistant","mercatorRaw","mercator","mercatorProjection","reclip","tany","conicConformalRaw","fy","conicConformal","equirectangularRaw","projection_equirectangular","conicEquidistantRaw","g","gy","nx","conicEquidistant","A1","A2","A3","A4","M","equalEarthRaw","l2","l6","equalEarth","gnomonicRaw","gnomonic","projection_identity","sa","tx","ty","kx","ky","naturalEarth1Raw","phi4","naturalEarth1","orthographicRaw","orthographic","stereographicRaw","stereographic","transverseMercatorRaw","transverseMercator","MapSeries_MapSeriesDataItem","_super","MapSeriesDataItem","_this","call","className","values","applyTheme","Object","tslib_es6","defineProperty","setValue","properties","setProperty","_east","_west","_south","_north","updateExtremes","getFeature","west","south","north","east","changed","utils_Math","component","invalidateDataItems","Series","MapSeries_MapSeries","MapSeries","isMeasured","nonScalingStroke","dataFields","ignoreBounds","tooltip","showInViewport","createDataItem","checkInclude","includes","excludes","id","indexOf","getPropertyValue","setPropertyValue","invalidateData","processIncExc","chart","handleObjectAdded","event","mapObject","newValue","parent","series","strokeWidth","_geodata","geodata","reverseGeodata","processReverseGeodata","data","madeFromGeoData","splice","disposeData","_dataSources","getDataSource","removeDispose","events","on","loadData","setDataSourceEvents","getFeatures","validateDataItems","dataItems","each","dataItem","Type","_mapObjects","dispatch","_northDefined","_southDefined","_westDefined","_eastDefined","processConfig","config","name_1","window","JSON","parse","Error","asIs","field","updateTooltipBounds","topParent","setBounds","maxWidth","maxHeight","Registry","registeredClasses","MapObject_MapObject","MapObject","layout","clickable","validate","itemReaderText","readerTitle","showTooltip","res","showTooltipOn","has","handleTooltipMove","addDisposer","ev","isHidden","setDataItem","applyAccessibility","Container","MapImage_MapImage","MapImage","latitude","geoPoint","validatePosition","d3Projection","d3Path","__disabled","multiPolygonToGeo","multiPolygon","utils_Array","surface","hole","geoArea","multiPointToGeo","multiLineToGeo","multiLine","pointToGeo","multiGeoToPoint","geoPoints","geoToPoint","multiGeoLineToMultiLine","multiGeoLine","multiGeoPolygonToMultipolygon","multiGeoPolygon","geoPolygon","getCircle","getBackground","stepLong","stepLat","ln","ll","lt","MapPolygon_MapPolygon","MapPolygon","createChild","shouldClone","applyOnClones","interfaceColors","InterfaceColorSet","fill","getFor","stroke","strokeOpacity","tooltipPosition","invalidate","pathGenerator","calculateVisualCenter","biggestArea","biggestPolygon","polylabel_default","_visualLongitude","_visualLatitude","measureElement","_adapterO","pixelWidth","pixelHeight","copyFrom","source","getTooltipX","convert","visualLongitude","visualLatitude","getTooltipY","MapPolygonSeries_MapPolygonSeriesDataItem","MapPolygonSeriesDataItem","_mapPolygon","mapPolygon_1","mapPolygons","create","addSprite","_disposers","Disposer","removeValue","_polygon","_multiPolygon","_geoPolygon","_multiGeoPolygon","MapPolygonSeries_MapPolygonSeries","MapPolygonSeries","clear","validateData","useGeodata","geoJSON","console","len","id_1","this_1","geodataNames","name","include","exclude","dataObject","Utils","mapPolygon","sortPolygonsBy","sortBy_1","reversed_1","sortPolygonsReversed","valA","valB","dirA","dirB","boxArea","dataContext","index","zIndex","propertyFields","_mapPolygons","polygonTemplate","List","template","focusable","getPolygonById","Iterator","iterator","_dataItem","Projection_Projection","Projection","_d3Projection","_d3Path","invalidateProjection","unproject","deltaLongitude","deltaLatitude","unrotate","intermediatePoint","pointA","pointB","position","multiDistance","positionToPoint","positionToGeoPoint","intermediatePointA","intermediatePointB","pa","pb","totalDistance","currentDistance","positionA","positionB","positionAB","SmallMap_SmallMap","SmallMap","_chart","align","valign","percentHeight","percentWidth","margin","background","fillOpacity","moveToPosition","updateMapSize","seriesContainer","rectangle","Rectangle","Color","verticalCenter","horizontalCenter","_series","handleSeriesAdded","handleSeriesRemoved","newSeries","clone","dataUsers","interactionsEnabled","hidden","rectPoint","spritePoint","seriesPointToGeo","zoomToGeoPoint","zoomLevel","get","set","updateRectangle","pixelX","pixelY","scaleRatio","bbox","group","node","getBBox","err","afterDraw","maskRectangle","hasKey","getKey","normalizePoint","wrapAngleTo180","latitude180","normalizeMultiline","multiline","Geo_geoToPoint","MapLineObject_MapLineObject","MapLineObject","adjustRotation","mapLine","shortestDistance","MapImageSeries_MapImageSeriesDataItem","MapImageSeriesDataItem","_mapImage","mapImage_1","mapImages","_geoPoint","multiPoint","MapImageSeries_MapImageSeries","MapImageSeries","multiGeoPoint","_parseDataFrom","mapImage","isDisposed","moveValue","_mapImages","validateDataElement","getImageById","MapLine_MapLine","MapLine","_imageListeners","createLine","Polyline","images","handleImagesToConnect","isReady","imagesToConnect","image","img","uid","disposer","property","_b","_c","convertedPoints","convertedSegmentPoints","slen","_arrow","lineObjects","handleGlobalScale","_lineObjects","handleLineObjectAdded","mapLineObject","arrow","triangle","Triangle","Percent","MapLineSeries_MapLineSeriesDataItem","MapLineSeriesDataItem","_mapLine","mapLine_1","mapLines","_multiLine","_multiGeoLine","_geoLine","geoLine","MapLineSeries_MapLineSeries","MapLineSeries","_mapLines","lineTemplate","getLineById","Graticule_Graticule","Graticule","GraticuleSeries_GraticuleSeriesDataItem","GraticuleSeriesDataItem","GraticuleSeries_GraticuleSeries","GraticuleSeries","longitudeStep","latitudeStep","singleSprite","disableType","hiddenInLegend","graticule_graticule","lineStrings","lineString","MapChart_MapChartDataItem","MapChartDataItem","SerialChart","MapChart_MapChart","MapChart","zoomDuration","zoomEasing","Ease","minZoomLevel","maxZoomLevel","_prevZoomGeoPoint","maxPanOut","homeZoomLevel","zoomStep","centerMapOnZoomOut","padding","backgroundSeries","minWidth","minHeight","once","handleAllInited","inert","resizable","handleMapTransform","handleDoubleHit","handleDrag","dragWhileResize","adapter","target","previousWidth","previousHeight","updateCenterGeoPoint","chartContainer","inited","_mapAnimation","allInited_1","dataInvalid","updateScaleRatio","_zoomGeoPointReal","chartContainerBg","dragStart","interactions","downPointers","getIndex","dragStop","handleMapDown","inertia","inertias","Interaction","body","hasFocused","Keyboard","getEventKey","_zoomControl","thumb","isFocused","pan","mouseWheelBehavior","interaction","handlePanDown","handlePanUp","panSprite","Circle","handlePanMove","opacity","panBehavior","svgPoint","pointer","htmlContainer","svgContainer","_downPointOrig","_downDeltaLongitude","_downDeltaLatitude","isResized","areTransformed","dln","dlt","dlg","downGeoLocal","local","geoLocal","goHome","disposer_1","updateZoomGeoPoint","seriesPoint","innerWidth","pixelPaddingLeft","innerHeight","pixelPaddingTop","maxLeft","maxRight","maxTop","maxBottom","seriesMaxLeft","seriesMaxRight","seriesMaxTop","seriesMaxBottom","seriesWidth","seriesHeight","_centerGeoPoint","ww","hh","minX","maxX","minY","maxY","zoomGeoPoint","applyInternalDefaults","language","cssScale","svgPointToGeo","zoomIn","handleWheel","mouseOptions","sensitivity","zoomOut","_mouseWheelDisposer","dispose","wheelable","draggable","_backgroundSeries","foundGraticule","deltaLong","deltaLat","initialScale","invalidateDataUsers","_fitWidth","_fitHeight","hScale","vScale","geoPointToSVG","geoPointToSeries","dataUser","duration","hasData_1","mapPoint","animate","zoomToMapObject","dataItem_1","polygonPoint","zoomToRectangle","level","splitLongitude","newLong","_prevZoomLevel","readerAlert","locale","_smallMap","smallMap","zoomControl","plusButton","exportable","minusButton","createSeries","rotateMap","raiseCriticalError","createClassInstance","configOrder","homeGeoPoint","centerGeoPoint","setPaper","paper","hideOverflow","color","setLegend","legend","setTapToActivate","isTouchProtected","handleTapToActivate","handleTapToActivateDeactivation","asFunction","hasLicense","Options","commercialLicense","licenses","match","MapSpline_MapSpline","MapSpline","Polyspline","tensionX","tensionY","MapArc_MapArc","MapArc","Polyarc","MapSplineSeries_MapSplineSeriesDataItem","MapSplineSeriesDataItem","MapSplineSeries_MapSplineSeries","MapSplineSeries","MapArcSeries_MapArcSeriesDataItem","MapArcSeriesDataItem","MapArcSeries_MapArcSeries","MapArcSeries","ZoomControl_ZoomControl","ZoomControl","Button","label","text","slider","handleBackgroundClick","updateThumbSize","handleThumbDrag","role","readerLive","fixLayout","marginTop","marginBottom","toFront","toBack","sprite","maxPower","LN2","minPower","power","updateThumb","isKey","stepCount","isDown","createBackground","RoundedRectangle","Mercator_Mercator","Mercator","sqrt1_2","SQRT1_2","sqrt2","sqrtPi","sinh","cosh","aitoffRaw","cosy","sincia","sinci","sinx","sinx_2","cosx_2","siny","sin_2y","sin2y","cos2y","sin2x_2","fx","dxdx","dxdy","dydx","dydy","augustRaw","tanPhi","sin3Eta","eta","xi","arcosh","arsinh","cosEta","coshXi","sqrt8","bakerRaw","cosPhi_2","tanPhi_2","hammerQuarticAuthalicRaw","solve","f0","f1","steps","mollweideBromleyTheta","cp","cpsinPhi","mollweideBromleyRaw","mollweideRaw","boggsRaw","sinusoidalRaw","collignonRaw","sqrt3","crasterRaw","eckert1Raw","eckert2Raw","eckert3Raw","eckert4Raw","eckert5Raw","eckert6Raw","eckert6","eisenlohrK","eisenlohrRaw","s0","_0","_1","s1","cos1","v2","vm1v","vp1v","deltatDeltaLambda","deltatDeltaPhi","deltacDeltat","deltacDeltaLambda","deltacDeltaPhi","deltavDeltaLambda","deltavDeltaPhi","deltaxDeltaLambda","deltaxDeltaPhi","deltayDeltaLambda","deltayDeltaPhi","denominator","faheyK","faheyRaw","foucautRaw","cosk","ginzburgPolyconic","xB","yB","m2","dAlphadLambda","xB2","dxBdPhi","dyBdPhi","dmdPhi","mcosAlpha","msinAlpha","dAlphadPhi","ginzburgPolyconicRaw","ginzburg8Raw","lambda4","gringortenRaw","sLambda","sPhi","r2","p2","a2","secPhi","drdPhi","dp2dPhi","mu","nu","zeta","g2","zetaMug","f2","df","gringortenHexadecant","gringortenHexadecantInvert","ellipticJ","twon","tanh","ellipticF","dPhi","guyouRaw","k_","K","psi","at","y_1","guyouComplexAtan","sinhPsi","cscPhi","cotPhi2","cotLambda2","ellipticFi","ellipticJi","tn","guyouComplexDivide","sinuMollweidePhi","sinuMollweideY","sinuMollweideRaw","homolosineRaw","kavrayskiy7Raw","pi_sqrt2","larriveeRaw","sqrtcosPhi","sinPhi_2","sinLambda_6","cosLambda_6","df0dPhi","df0dLambda","df1dPhi","df1dLambda","denom","laskowskiRaw","lambdaPhi","littrowRaw","y2_1","x2_y2_1","millerRaw","miller","sqrt6","sqrt7","mtFlatPolarParabolicRaw","mtFlatPolarQuarticRaw","sinTheta_2","mtFlatPolarSinusoidalRaw","naturalEarth2Raw","phi6","nellHammerRaw","nicolosiRaw","b2","b2d2","d2b2","N","x2y2","pi2","pattersonK1","pattersonK2","pattersonK3","pattersonK4","pattersonC1","pattersonC2","pattersonC3","pattersonC4","pattersonRaw","yc","polyconicRaw","octahedron","face","collignonK","robinsonRaw","i0","di","bx","by","yy","timesRaw","vanDerGrintenRaw","sinTheta","cosTheta","G","P","P2","P2_A2","G_P2","Q","x2_y2","c3","m1","theta1","vanDerGrinten2Raw","vanDerGrinten3Raw","vanDerGrinten4Raw","B2","C","C2","BC","B_C2","B_3C","D","D2","C_","B_C","F_","sqrtF","wagner6Raw","wiechelRaw","sin1_Phi","cosLambda","sinLambda","winkel3Raw","F","cosphi","sinphi","sin_2phi","sin2phi","cos2phi","sinlambda","coslambda_2","sinlambda_2","sin2lambda_2","E","dxdlambda","dxdphi","dydlambda","dydphi","dlambda","dphi","Miller_Miller","Miller","Eckert6_Eckert6","Eckert6","Orthographic_Orthographic","Orthographic","Stereographic_Stereographic","Stereographic","Albers_Albers","Albers","AlbersUsa_AlbersUsa","AlbersUsa","NaturalEarth1_NaturalEarth1","NaturalEarth1","AzimuthalEqualArea_AzimuthalEqualArea","AzimuthalEqualArea","EqualEarth_EqualEarth","EqualEarth","am4maps","maps_namespaceObject","TinyQueue","defaultCompare","_down","item","_up","top","bottom","pos","halfLength","best","Queue","__webpack_require__","polylabel","debug","cellSize","degeneratePoleOfInaccessibility","cellQueue","compareMax","Cell","bestCell","getCentroidCell","bboxCell","numProbes","cell","poleOfInaccessibility","inside","minDistSq","getSegDistSq","pointToPolygonDist","SQRT2","px","py","default","module","exports"],"mappings":";;;;;;;;;;;;;;;;;;;0kKAAeA,EAAA,SAASC,EAAGC,GACzB,OAAOD,EAAIC,GAAK,EAAID,EAAIC,EAAI,EAAID,GAAKC,EAAI,EAAIC,KCChCC,EAAA,SAASC,GACtB,IAAIC,EAAQD,EACRE,EAAUF,EAOd,SAASG,EAAKP,EAAGQ,EAAGC,EAAIC,GAGtB,IAFU,MAAND,IAAYA,EAAK,GACX,MAANC,IAAYA,EAAKV,EAAEW,QAChBF,EAAKC,GAAI,CACd,IAAME,EAAOH,EAAKC,IAAQ,EACtBJ,EAAQN,EAAEY,GAAMJ,GAAK,EAAGC,EAAKG,EAAM,EAClCF,EAAKE,EAEZ,OAAOH,EAqBT,OAlCiB,IAAbL,EAAEO,SACJN,EAAQ,SAACQ,EAAGL,GAAJ,OAAUJ,EAAES,GAAKL,GACzBF,EAmCJ,SAA6BF,GAC3B,OAAO,SAACS,EAAGL,GAAJ,OAAUT,EAAUK,EAAES,GAAIL,IApCrBM,CAAoBV,KAgCxBG,OAAMQ,OAPd,SAAgBf,EAAGQ,EAAGC,EAA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,EAAAx9C,GAAAqV,GAAAooC,EAAAl8C,GAAA+T,IAAAD,IAAAC,KAEAvG,EAAA,GACA/O,EAAAP,EAAA,GACA8B,EAAA9B,EAAA,IAESsP,EAAA,IACT/O,GAAAqV,EAAAtG,EACAxN,GAAA+T,EAAAvG,GAOA,OAHAsG,EAAAmoC,EAAAx9C,GAGAqV,GAFAC,EAAAmoC,EAAAl8C,GAEA+T,EA9JA8mC,EAAAsB,UAAAtB,IAAAsB,SAEAC,EAAAC,QAAAtB,EACAqB,EAAAC,QAAAF,QAAApB","file":"maps.js","sourcesContent":["export default function(a, b) {\n return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/ascending.js","import ascending from \"./ascending.js\";\n\nexport default function(f) {\n let delta = f;\n let compare = f;\n\n if (f.length === 1) {\n delta = (d, x) => f(d) - x;\n compare = ascendingComparator(f);\n }\n\n function left(a, x, lo, hi) {\n if (lo == null) lo = 0;\n if (hi == null) hi = a.length;\n while (lo < hi) {\n const mid = (lo + hi) >>> 1;\n if (compare(a[mid], x) < 0) lo = mid + 1;\n else hi = mid;\n }\n return lo;\n }\n\n function right(a, x, lo, hi) {\n if (lo == null) lo = 0;\n if (hi == null) hi = a.length;\n while (lo < hi) {\n const mid = (lo + hi) >>> 1;\n if (compare(a[mid], x) > 0) hi = mid;\n else lo = mid + 1;\n }\n return lo;\n }\n\n function center(a, x, lo, hi) {\n if (lo == null) lo = 0;\n if (hi == null) hi = a.length;\n const i = left(a, x, lo, hi - 1);\n return i > lo && delta(a[i - 1], x) > -delta(a[i], x) ? i - 1 : i;\n }\n\n return {left, center, right};\n}\n\nfunction ascendingComparator(f) {\n return (d, x) => ascending(f(d), x);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/bisector.js","export default function(x) {\n return x === null ? NaN : +x;\n}\n\nexport function* numbers(values, valueof) {\n if (valueof === undefined) {\n for (let value of values) {\n if (value != null && (value = +value) >= value) {\n yield value;\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null && (value = +value) >= value) {\n yield value;\n }\n }\n }\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/number.js","import ascending from \"./ascending.js\";\nimport bisector from \"./bisector.js\";\nimport number from \"./number.js\";\n\nconst ascendingBisect = bisector(ascending);\nexport const bisectRight = ascendingBisect.right;\nexport const bisectLeft = ascendingBisect.left;\nexport const bisectCenter = bisector(number).center;\nexport default bisectRight;\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/bisect.js","// https://github.com/python/cpython/blob/a74eea238f5baba15797e2e8b570d153bc8690a7/Modules/mathmodule.c#L1423\nexport class Adder {\n constructor() {\n this._partials = new Float64Array(32);\n this._n = 0;\n }\n add(x) {\n const p = this._partials;\n let i = 0;\n for (let j = 0; j < this._n && j < 32; j++) {\n const y = p[j],\n hi = x + y,\n lo = Math.abs(x) < Math.abs(y) ? x - (hi - y) : y - (hi - x);\n if (lo) p[i++] = lo;\n x = hi;\n }\n p[i] = x;\n this._n = i + 1;\n return this;\n }\n valueOf() {\n const p = this._partials;\n let n = this._n, x, y, lo, hi = 0;\n if (n > 0) {\n hi = p[--n];\n while (n > 0) {\n x = hi;\n y = p[--n];\n hi = x + y;\n lo = y - (hi - x);\n if (lo) break;\n }\n if (n > 0 && ((lo < 0 && p[n - 1] < 0) || (lo > 0 && p[n - 1] > 0))) {\n y = lo * 2;\n x = hi + y;\n if (y == x - hi) hi = x;\n }\n }\n return hi;\n }\n}\n\nexport default function(values, valueof) {\n const adder = new Adder();\n if (valueof === undefined) {\n for (let value of values) {\n if (value = +value) {\n adder.add(value);\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if (value = +valueof(value, ++index, values)) {\n adder.add(value);\n }\n }\n }\n return +adder;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/fsum.js","var array = Array.prototype;\n\nexport var slice = array.slice;\nexport var map = array.map;\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/array.js","var e10 = Math.sqrt(50),\n e5 = Math.sqrt(10),\n e2 = Math.sqrt(2);\n\nexport default function(start, stop, count) {\n var reverse,\n i = -1,\n n,\n ticks,\n step;\n\n stop = +stop, start = +start, count = +count;\n if (start === stop && count > 0) return [start];\n if (reverse = stop < start) n = start, start = stop, stop = n;\n if ((step = tickIncrement(start, stop, count)) === 0 || !isFinite(step)) return [];\n\n if (step > 0) {\n start = Math.ceil(start / step);\n stop = Math.floor(stop / step);\n ticks = new Array(n = Math.ceil(stop - start + 1));\n while (++i < n) ticks[i] = (start + i) * step;\n } else {\n step = -step;\n start = Math.ceil(start * step);\n stop = Math.floor(stop * step);\n ticks = new Array(n = Math.ceil(stop - start + 1));\n while (++i < n) ticks[i] = (start + i) / step;\n }\n\n if (reverse) ticks.reverse();\n\n return ticks;\n}\n\nexport function tickIncrement(start, stop, count) {\n var step = (stop - start) / Math.max(0, count),\n power = Math.floor(Math.log(step) / Math.LN10),\n error = step / Math.pow(10, power);\n return power >= 0\n ? (error >= e10 ? 10 : error >= e5 ? 5 : error >= e2 ? 2 : 1) * Math.pow(10, power)\n : -Math.pow(10, -power) / (error >= e10 ? 10 : error >= e5 ? 5 : error >= e2 ? 2 : 1);\n}\n\nexport function tickStep(start, stop, count) {\n var step0 = Math.abs(stop - start) / Math.max(0, count),\n step1 = Math.pow(10, Math.floor(Math.log(step0) / Math.LN10)),\n error = step0 / step1;\n if (error >= e10) step1 *= 10;\n else if (error >= e5) step1 *= 5;\n else if (error >= e2) step1 *= 2;\n return stop < start ? -step1 : step1;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/ticks.js","import quantile from \"./quantile.js\";\n\nexport default function(values, valueof) {\n return quantile(values, 0.5, valueof);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/median.js","function* flatten(arrays) {\n for (const array of arrays) {\n yield* array;\n }\n}\n\nexport default function merge(arrays) {\n return Array.from(flatten(arrays));\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/merge.js","export default function(source, keys) {\n return Array.from(keys, key => source[key]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/permute.js","export default function(start, stop, step) {\n start = +start, stop = +stop, step = (n = arguments.length) < 2 ? (stop = start, start = 0, 1) : n < 3 ? 1 : +step;\n\n var i = -1,\n n = Math.max(0, Math.ceil((stop - start) / step)) | 0,\n range = new Array(n);\n\n while (++i < n) {\n range[i] = start + i * step;\n }\n\n return range;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/range.js","export default shuffler(Math.random);\n\nexport function shuffler(random) {\n return function shuffle(array, i0 = 0, i1 = array.length) {\n let m = i1 - (i0 = +i0);\n while (m) {\n const i = random() * m-- | 0, t = array[m + i0];\n array[m + i0] = array[i + i0];\n array[i + i0] = t;\n }\n return array;\n };\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-array/src/shuffle.js","export var epsilon = 1e-6;\nexport var epsilon2 = 1e-12;\nexport var pi = Math.PI;\nexport var halfPi = pi / 2;\nexport var quarterPi = pi / 4;\nexport var tau = pi * 2;\n\nexport var degrees = 180 / pi;\nexport var radians = pi / 180;\n\nexport var abs = Math.abs;\nexport var atan = Math.atan;\nexport var atan2 = Math.atan2;\nexport var cos = Math.cos;\nexport var ceil = Math.ceil;\nexport var exp = Math.exp;\nexport var floor = Math.floor;\nexport var hypot = Math.hypot;\nexport var log = Math.log;\nexport var pow = Math.pow;\nexport var sin = Math.sin;\nexport var sign = Math.sign || function(x) { return x > 0 ? 1 : x < 0 ? -1 : 0; };\nexport var sqrt = Math.sqrt;\nexport var tan = Math.tan;\n\nexport function acos(x) {\n return x > 1 ? 0 : x < -1 ? pi : Math.acos(x);\n}\n\nexport function asin(x) {\n return x > 1 ? halfPi : x < -1 ? -halfPi : Math.asin(x);\n}\n\nexport function haversin(x) {\n return (x = sin(x / 2)) * x;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/math.js","export default function noop() {}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/noop.js","function streamGeometry(geometry, stream) {\n if (geometry && streamGeometryType.hasOwnProperty(geometry.type)) {\n streamGeometryType[geometry.type](geometry, stream);\n }\n}\n\nvar streamObjectType = {\n Feature: function(object, stream) {\n streamGeometry(object.geometry, stream);\n },\n FeatureCollection: function(object, stream) {\n var features = object.features, i = -1, n = features.length;\n while (++i < n) streamGeometry(features[i].geometry, stream);\n }\n};\n\nvar streamGeometryType = {\n Sphere: function(object, stream) {\n stream.sphere();\n },\n Point: function(object, stream) {\n object = object.coordinates;\n stream.point(object[0], object[1], object[2]);\n },\n MultiPoint: function(object, stream) {\n var coordinates = object.coordinates, i = -1, n = coordinates.length;\n while (++i < n) object = coordinates[i], stream.point(object[0], object[1], object[2]);\n },\n LineString: function(object, stream) {\n streamLine(object.coordinates, stream, 0);\n },\n MultiLineString: function(object, stream) {\n var coordinates = object.coordinates, i = -1, n = coordinates.length;\n while (++i < n) streamLine(coordinates[i], stream, 0);\n },\n Polygon: function(object, stream) {\n streamPolygon(object.coordinates, stream);\n },\n MultiPolygon: function(object, stream) {\n var coordinates = object.coordinates, i = -1, n = coordinates.length;\n while (++i < n) streamPolygon(coordinates[i], stream);\n },\n GeometryCollection: function(object, stream) {\n var geometries = object.geometries, i = -1, n = geometries.length;\n while (++i < n) streamGeometry(geometries[i], stream);\n }\n};\n\nfunction streamLine(coordinates, stream, closed) {\n var i = -1, n = coordinates.length - closed, coordinate;\n stream.lineStart();\n while (++i < n) coordinate = coordinates[i], stream.point(coordinate[0], coordinate[1], coordinate[2]);\n stream.lineEnd();\n}\n\nfunction streamPolygon(coordinates, stream) {\n var i = -1, n = coordinates.length;\n stream.polygonStart();\n while (++i < n) streamLine(coordinates[i], stream, 1);\n stream.polygonEnd();\n}\n\nexport default function(object, stream) {\n if (object && streamObjectType.hasOwnProperty(object.type)) {\n streamObjectType[object.type](object, stream);\n } else {\n streamGeometry(object, stream);\n }\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/stream.js","import {Adder} from \"d3-array\";\nimport {atan2, cos, quarterPi, radians, sin, tau} from \"./math.js\";\nimport noop from \"./noop.js\";\nimport stream from \"./stream.js\";\n\nexport var areaRingSum = new Adder();\n\n// hello?\n\nvar areaSum = new Adder(),\n lambda00,\n phi00,\n lambda0,\n cosPhi0,\n sinPhi0;\n\nexport var areaStream = {\n point: noop,\n lineStart: noop,\n lineEnd: noop,\n polygonStart: function() {\n areaRingSum = new Adder();\n areaStream.lineStart = areaRingStart;\n areaStream.lineEnd = areaRingEnd;\n },\n polygonEnd: function() {\n var areaRing = +areaRingSum;\n areaSum.add(areaRing < 0 ? tau + areaRing : areaRing);\n this.lineStart = this.lineEnd = this.point = noop;\n },\n sphere: function() {\n areaSum.add(tau);\n }\n};\n\nfunction areaRingStart() {\n areaStream.point = areaPointFirst;\n}\n\nfunction areaRingEnd() {\n areaPoint(lambda00, phi00);\n}\n\nfunction areaPointFirst(lambda, phi) {\n areaStream.point = areaPoint;\n lambda00 = lambda, phi00 = phi;\n lambda *= radians, phi *= radians;\n lambda0 = lambda, cosPhi0 = cos(phi = phi / 2 + quarterPi), sinPhi0 = sin(phi);\n}\n\nfunction areaPoint(lambda, phi) {\n lambda *= radians, phi *= radians;\n phi = phi / 2 + quarterPi; // half the angular distance from south pole\n\n // Spherical excess E for a spherical triangle with vertices: south pole,\n // previous point, current point. Uses a formula derived from Cagnoli’s\n // theorem. See Todhunter, Spherical Trig. (1871), Sec. 103, Eq. (2).\n var dLambda = lambda - lambda0,\n sdLambda = dLambda >= 0 ? 1 : -1,\n adLambda = sdLambda * dLambda,\n cosPhi = cos(phi),\n sinPhi = sin(phi),\n k = sinPhi0 * sinPhi,\n u = cosPhi0 * cosPhi + k * cos(adLambda),\n v = k * sdLambda * sin(adLambda);\n areaRingSum.add(atan2(v, u));\n\n // Advance the previous points.\n lambda0 = lambda, cosPhi0 = cosPhi, sinPhi0 = sinPhi;\n}\n\nexport default function(object) {\n areaSum = new Adder();\n stream(object, areaStream);\n return areaSum * 2;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/area.js","import {Adder} from \"d3-array\";\nimport {areaStream, areaRingSum} from \"./area.js\";\nimport {cartesian, cartesianCross, cartesianNormalizeInPlace, spherical} from \"./cartesian.js\";\nimport {abs, degrees, epsilon, radians} from \"./math.js\";\nimport stream from \"./stream.js\";\n\nvar lambda0, phi0, lambda1, phi1, // bounds\n lambda2, // previous lambda-coordinate\n lambda00, phi00, // first point\n p0, // previous 3D point\n deltaSum,\n ranges,\n range;\n\nvar boundsStream = {\n point: boundsPoint,\n lineStart: boundsLineStart,\n lineEnd: boundsLineEnd,\n polygonStart: function() {\n boundsStream.point = boundsRingPoint;\n boundsStream.lineStart = boundsRingStart;\n boundsStream.lineEnd = boundsRingEnd;\n deltaSum = new Adder();\n areaStream.polygonStart();\n },\n polygonEnd: function() {\n areaStream.polygonEnd();\n boundsStream.point = boundsPoint;\n boundsStream.lineStart = boundsLineStart;\n boundsStream.lineEnd = boundsLineEnd;\n if (areaRingSum < 0) lambda0 = -(lambda1 = 180), phi0 = -(phi1 = 90);\n else if (deltaSum > epsilon) phi1 = 90;\n else if (deltaSum < -epsilon) phi0 = -90;\n range[0] = lambda0, range[1] = lambda1;\n },\n sphere: function() {\n lambda0 = -(lambda1 = 180), phi0 = -(phi1 = 90);\n }\n};\n\nfunction boundsPoint(lambda, phi) {\n ranges.push(range = [lambda0 = lambda, lambda1 = lambda]);\n if (phi < phi0) phi0 = phi;\n if (phi > phi1) phi1 = phi;\n}\n\nfunction linePoint(lambda, phi) {\n var p = cartesian([lambda * radians, phi * radians]);\n if (p0) {\n var normal = cartesianCross(p0, p),\n equatorial = [normal[1], -normal[0], 0],\n inflection = cartesianCross(equatorial, normal);\n cartesianNormalizeInPlace(inflection);\n inflection = spherical(inflection);\n var delta = lambda - lambda2,\n sign = delta > 0 ? 1 : -1,\n lambdai = inflection[0] * degrees * sign,\n phii,\n antimeridian = abs(delta) > 180;\n if (antimeridian ^ (sign * lambda2 < lambdai && lambdai < sign * lambda)) {\n phii = inflection[1] * degrees;\n if (phii > phi1) phi1 = phii;\n } else if (lambdai = (lambdai + 360) % 360 - 180, antimeridian ^ (sign * lambda2 < lambdai && lambdai < sign * lambda)) {\n phii = -inflection[1] * degrees;\n if (phii < phi0) phi0 = phii;\n } else {\n if (phi < phi0) phi0 = phi;\n if (phi > phi1) phi1 = phi;\n }\n if (antimeridian) {\n if (lambda < lambda2) {\n if (angle(lambda0, lambda) > angle(lambda0, lambda1)) lambda1 = lambda;\n } else {\n if (angle(lambda, lambda1) > angle(lambda0, lambda1)) lambda0 = lambda;\n }\n } else {\n if (lambda1 >= lambda0) {\n if (lambda < lambda0) lambda0 = lambda;\n if (lambda > lambda1) lambda1 = lambda;\n } else {\n if (lambda > lambda2) {\n if (angle(lambda0, lambda) > angle(lambda0, lambda1)) lambda1 = lambda;\n } else {\n if (angle(lambda, lambda1) > angle(lambda0, lambda1)) lambda0 = lambda;\n }\n }\n }\n } else {\n ranges.push(range = [lambda0 = lambda, lambda1 = lambda]);\n }\n if (phi < phi0) phi0 = phi;\n if (phi > phi1) phi1 = phi;\n p0 = p, lambda2 = lambda;\n}\n\nfunction boundsLineStart() {\n boundsStream.point = linePoint;\n}\n\nfunction boundsLineEnd() {\n range[0] = lambda0, range[1] = lambda1;\n boundsStream.point = boundsPoint;\n p0 = null;\n}\n\nfunction boundsRingPoint(lambda, phi) {\n if (p0) {\n var delta = lambda - lambda2;\n deltaSum.add(abs(delta) > 180 ? delta + (delta > 0 ? 360 : -360) : delta);\n } else {\n lambda00 = lambda, phi00 = phi;\n }\n areaStream.point(lambda, phi);\n linePoint(lambda, phi);\n}\n\nfunction boundsRingStart() {\n areaStream.lineStart();\n}\n\nfunction boundsRingEnd() {\n boundsRingPoint(lambda00, phi00);\n areaStream.lineEnd();\n if (abs(deltaSum) > epsilon) lambda0 = -(lambda1 = 180);\n range[0] = lambda0, range[1] = lambda1;\n p0 = null;\n}\n\n// Finds the left-right distance between two longitudes.\n// This is almost the same as (lambda1 - lambda0 + 360°) % 360°, except that we want\n// the distance between ±180° to be 360°.\nfunction angle(lambda0, lambda1) {\n return (lambda1 -= lambda0) < 0 ? lambda1 + 360 : lambda1;\n}\n\nfunction rangeCompare(a, b) {\n return a[0] - b[0];\n}\n\nfunction rangeContains(range, x) {\n return range[0] <= range[1] ? range[0] <= x && x <= range[1] : x < range[0] || range[1] < x;\n}\n\nexport default function(feature) {\n var i, n, a, b, merged, deltaMax, delta;\n\n phi1 = lambda1 = -(lambda0 = phi0 = Infinity);\n ranges = [];\n stream(feature, boundsStream);\n\n // First, sort ranges by their minimum longitudes.\n if (n = ranges.length) {\n ranges.sort(rangeCompare);\n\n // Then, merge any ranges that overlap.\n for (i = 1, a = ranges[0], merged = [a]; i < n; ++i) {\n b = ranges[i];\n if (rangeContains(a, b[0]) || rangeContains(a, b[1])) {\n if (angle(a[0], b[1]) > angle(a[0], a[1])) a[1] = b[1];\n if (angle(b[0], a[1]) > angle(a[0], a[1])) a[0] = b[0];\n } else {\n merged.push(a = b);\n }\n }\n\n // Finally, find the largest gap between the merged ranges.\n // The final bounding box will be the inverse of this gap.\n for (deltaMax = -Infinity, n = merged.length - 1, i = 0, a = merged[n]; i <= n; a = b, ++i) {\n b = merged[i];\n if ((delta = angle(a[1], b[0])) > deltaMax) deltaMax = delta, lambda0 = b[0], lambda1 = a[1];\n }\n }\n\n ranges = range = null;\n\n return lambda0 === Infinity || phi0 === Infinity\n ? [[NaN, NaN], [NaN, NaN]]\n : [[lambda0, phi0], [lambda1, phi1]];\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/bounds.js","import {asin, atan2, cos, sin, sqrt} from \"./math.js\";\n\nexport function spherical(cartesian) {\n return [atan2(cartesian[1], cartesian[0]), asin(cartesian[2])];\n}\n\nexport function cartesian(spherical) {\n var lambda = spherical[0], phi = spherical[1], cosPhi = cos(phi);\n return [cosPhi * cos(lambda), cosPhi * sin(lambda), sin(phi)];\n}\n\nexport function cartesianDot(a, b) {\n return a[0] * b[0] + a[1] * b[1] + a[2] * b[2];\n}\n\nexport function cartesianCross(a, b) {\n return [a[1] * b[2] - a[2] * b[1], a[2] * b[0] - a[0] * b[2], a[0] * b[1] - a[1] * b[0]];\n}\n\n// TODO return a\nexport function cartesianAddInPlace(a, b) {\n a[0] += b[0], a[1] += b[1], a[2] += b[2];\n}\n\nexport function cartesianScale(vector, k) {\n return [vector[0] * k, vector[1] * k, vector[2] * k];\n}\n\n// TODO return d\nexport function cartesianNormalizeInPlace(d) {\n var l = sqrt(d[0] * d[0] + d[1] * d[1] + d[2] * d[2]);\n d[0] /= l, d[1] /= l, d[2] /= l;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/cartesian.js","import {Adder} from \"d3-array\";\nimport {asin, atan2, cos, degrees, epsilon, epsilon2, hypot, radians, sin, sqrt} from \"./math.js\";\nimport noop from \"./noop.js\";\nimport stream from \"./stream.js\";\n\nvar W0, W1,\n X0, Y0, Z0,\n X1, Y1, Z1,\n X2, Y2, Z2,\n lambda00, phi00, // first point\n x0, y0, z0; // previous point\n\nvar centroidStream = {\n sphere: noop,\n point: centroidPoint,\n lineStart: centroidLineStart,\n lineEnd: centroidLineEnd,\n polygonStart: function() {\n centroidStream.lineStart = centroidRingStart;\n centroidStream.lineEnd = centroidRingEnd;\n },\n polygonEnd: function() {\n centroidStream.lineStart = centroidLineStart;\n centroidStream.lineEnd = centroidLineEnd;\n }\n};\n\n// Arithmetic mean of Cartesian vectors.\nfunction centroidPoint(lambda, phi) {\n lambda *= radians, phi *= radians;\n var cosPhi = cos(phi);\n centroidPointCartesian(cosPhi * cos(lambda), cosPhi * sin(lambda), sin(phi));\n}\n\nfunction centroidPointCartesian(x, y, z) {\n ++W0;\n X0 += (x - X0) / W0;\n Y0 += (y - Y0) / W0;\n Z0 += (z - Z0) / W0;\n}\n\nfunction centroidLineStart() {\n centroidStream.point = centroidLinePointFirst;\n}\n\nfunction centroidLinePointFirst(lambda, phi) {\n lambda *= radians, phi *= radians;\n var cosPhi = cos(phi);\n x0 = cosPhi * cos(lambda);\n y0 = cosPhi * sin(lambda);\n z0 = sin(phi);\n centroidStream.point = centroidLinePoint;\n centroidPointCartesian(x0, y0, z0);\n}\n\nfunction centroidLinePoint(lambda, phi) {\n lambda *= radians, phi *= radians;\n var cosPhi = cos(phi),\n x = cosPhi * cos(lambda),\n y = cosPhi * sin(lambda),\n z = sin(phi),\n w = atan2(sqrt((w = y0 * z - z0 * y) * w + (w = z0 * x - x0 * z) * w + (w = x0 * y - y0 * x) * w), x0 * x + y0 * y + z0 * z);\n W1 += w;\n X1 += w * (x0 + (x0 = x));\n Y1 += w * (y0 + (y0 = y));\n Z1 += w * (z0 + (z0 = z));\n centroidPointCartesian(x0, y0, z0);\n}\n\nfunction centroidLineEnd() {\n centroidStream.point = centroidPoint;\n}\n\n// See J. E. Brock, The Inertia Tensor for a Spherical Triangle,\n// J. Applied Mechanics 42, 239 (1975).\nfunction centroidRingStart() {\n centroidStream.point = centroidRingPointFirst;\n}\n\nfunction centroidRingEnd() {\n centroidRingPoint(lambda00, phi00);\n centroidStream.point = centroidPoint;\n}\n\nfunction centroidRingPointFirst(lambda, phi) {\n lambda00 = lambda, phi00 = phi;\n lambda *= radians, phi *= radians;\n centroidStream.point = centroidRingPoint;\n var cosPhi = cos(phi);\n x0 = cosPhi * cos(lambda);\n y0 = cosPhi * sin(lambda);\n z0 = sin(phi);\n centroidPointCartesian(x0, y0, z0);\n}\n\nfunction centroidRingPoint(lambda, phi) {\n lambda *= radians, phi *= radians;\n var cosPhi = cos(phi),\n x = cosPhi * cos(lambda),\n y = cosPhi * sin(lambda),\n z = sin(phi),\n cx = y0 * z - z0 * y,\n cy = z0 * x - x0 * z,\n cz = x0 * y - y0 * x,\n m = hypot(cx, cy, cz),\n w = asin(m), // line weight = angle\n v = m && -w / m; // area weight multiplier\n X2.add(v * cx);\n Y2.add(v * cy);\n Z2.add(v * cz);\n W1 += w;\n X1 += w * (x0 + (x0 = x));\n Y1 += w * (y0 + (y0 = y));\n Z1 += w * (z0 + (z0 = z));\n centroidPointCartesian(x0, y0, z0);\n}\n\nexport default function(object) {\n W0 = W1 =\n X0 = Y0 = Z0 =\n X1 = Y1 = Z1 = 0;\n X2 = new Adder();\n Y2 = new Adder();\n Z2 = new Adder();\n stream(object, centroidStream);\n\n var x = +X2,\n y = +Y2,\n z = +Z2,\n m = hypot(x, y, z);\n\n // If the area-weighted ccentroid is undefined, fall back to length-weighted ccentroid.\n if (m < epsilon2) {\n x = X1, y = Y1, z = Z1;\n // If the feature has zero length, fall back to arithmetic mean of point vectors.\n if (W1 < epsilon) x = X0, y = Y0, z = Z0;\n m = hypot(x, y, z);\n // If the feature still has an undefined ccentroid, then return.\n if (m < epsilon2) return [NaN, NaN];\n }\n\n return [atan2(y, x) * degrees, asin(z / m) * degrees];\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/centroid.js","export default function(x) {\n return function() {\n return x;\n };\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/constant.js","export default function(a, b) {\n\n function compose(x, y) {\n return x = a(x, y), b(x[0], x[1]);\n }\n\n if (a.invert && b.invert) compose.invert = function(x, y) {\n return x = b.invert(x, y), x && a.invert(x[0], x[1]);\n };\n\n return compose;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/compose.js","import compose from \"./compose.js\";\nimport {abs, asin, atan2, cos, degrees, pi, radians, sin, tau} from \"./math.js\";\n\nfunction rotationIdentity(lambda, phi) {\n return [abs(lambda) > pi ? lambda + Math.round(-lambda / tau) * tau : lambda, phi];\n}\n\nrotationIdentity.invert = rotationIdentity;\n\nexport function rotateRadians(deltaLambda, deltaPhi, deltaGamma) {\n return (deltaLambda %= tau) ? (deltaPhi || deltaGamma ? compose(rotationLambda(deltaLambda), rotationPhiGamma(deltaPhi, deltaGamma))\n : rotationLambda(deltaLambda))\n : (deltaPhi || deltaGamma ? rotationPhiGamma(deltaPhi, deltaGamma)\n : rotationIdentity);\n}\n\nfunction forwardRotationLambda(deltaLambda) {\n return function(lambda, phi) {\n return lambda += deltaLambda, [lambda > pi ? lambda - tau : lambda < -pi ? lambda + tau : lambda, phi];\n };\n}\n\nfunction rotationLambda(deltaLambda) {\n var rotation = forwardRotationLambda(deltaLambda);\n rotation.invert = forwardRotationLambda(-deltaLambda);\n return rotation;\n}\n\nfunction rotationPhiGamma(deltaPhi, deltaGamma) {\n var cosDeltaPhi = cos(deltaPhi),\n sinDeltaPhi = sin(deltaPhi),\n cosDeltaGamma = cos(deltaGamma),\n sinDeltaGamma = sin(deltaGamma);\n\n function rotation(lambda, phi) {\n var cosPhi = cos(phi),\n x = cos(lambda) * cosPhi,\n y = sin(lambda) * cosPhi,\n z = sin(phi),\n k = z * cosDeltaPhi + x * sinDeltaPhi;\n return [\n atan2(y * cosDeltaGamma - k * sinDeltaGamma, x * cosDeltaPhi - z * sinDeltaPhi),\n asin(k * cosDeltaGamma + y * sinDeltaGamma)\n ];\n }\n\n rotation.invert = function(lambda, phi) {\n var cosPhi = cos(phi),\n x = cos(lambda) * cosPhi,\n y = sin(lambda) * cosPhi,\n z = sin(phi),\n k = z * cosDeltaGamma - y * sinDeltaGamma;\n return [\n atan2(y * cosDeltaGamma + z * sinDeltaGamma, x * cosDeltaPhi + k * sinDeltaPhi),\n asin(k * cosDeltaPhi - x * sinDeltaPhi)\n ];\n };\n\n return rotation;\n}\n\nexport default function(rotate) {\n rotate = rotateRadians(rotate[0] * radians, rotate[1] * radians, rotate.length > 2 ? rotate[2] * radians : 0);\n\n function forward(coordinates) {\n coordinates = rotate(coordinates[0] * radians, coordinates[1] * radians);\n return coordinates[0] *= degrees, coordinates[1] *= degrees, coordinates;\n }\n\n forward.invert = function(coordinates) {\n coordinates = rotate.invert(coordinates[0] * radians, coordinates[1] * radians);\n return coordinates[0] *= degrees, coordinates[1] *= degrees, coordinates;\n };\n\n return forward;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/rotation.js","import {cartesian, cartesianNormalizeInPlace, spherical} from \"./cartesian.js\";\nimport constant from \"./constant.js\";\nimport {acos, cos, degrees, epsilon, radians, sin, tau} from \"./math.js\";\nimport {rotateRadians} from \"./rotation.js\";\n\n// Generates a circle centered at [0°, 0°], with a given radius and precision.\nexport function circleStream(stream, radius, delta, direction, t0, t1) {\n if (!delta) return;\n var cosRadius = cos(radius),\n sinRadius = sin(radius),\n step = direction * delta;\n if (t0 == null) {\n t0 = radius + direction * tau;\n t1 = radius - step / 2;\n } else {\n t0 = circleRadius(cosRadius, t0);\n t1 = circleRadius(cosRadius, t1);\n if (direction > 0 ? t0 < t1 : t0 > t1) t0 += direction * tau;\n }\n for (var point, t = t0; direction > 0 ? t > t1 : t < t1; t -= step) {\n point = spherical([cosRadius, -sinRadius * cos(t), -sinRadius * sin(t)]);\n stream.point(point[0], point[1]);\n }\n}\n\n// Returns the signed angle of a cartesian point relative to [cosRadius, 0, 0].\nfunction circleRadius(cosRadius, point) {\n point = cartesian(point), point[0] -= cosRadius;\n cartesianNormalizeInPlace(point);\n var radius = acos(-point[1]);\n return ((-point[2] < 0 ? -radius : radius) + tau - epsilon) % tau;\n}\n\nexport default function() {\n var center = constant([0, 0]),\n radius = constant(90),\n precision = constant(6),\n ring,\n rotate,\n stream = {point: point};\n\n function point(x, y) {\n ring.push(x = rotate(x, y));\n x[0] *= degrees, x[1] *= degrees;\n }\n\n function circle() {\n var c = center.apply(this, arguments),\n r = radius.apply(this, arguments) * radians,\n p = precision.apply(this, arguments) * radians;\n ring = [];\n rotate = rotateRadians(-c[0] * radians, -c[1] * radians, 0).invert;\n circleStream(stream, r, p, 1);\n c = {type: \"Polygon\", coordinates: [ring]};\n ring = rotate = null;\n return c;\n }\n\n circle.center = function(_) {\n return arguments.length ? (center = typeof _ === \"function\" ? _ : constant([+_[0], +_[1]]), circle) : center;\n };\n\n circle.radius = function(_) {\n return arguments.length ? (radius = typeof _ === \"function\" ? _ : constant(+_), circle) : radius;\n };\n\n circle.precision = function(_) {\n return arguments.length ? (precision = typeof _ === \"function\" ? _ : constant(+_), circle) : precision;\n };\n\n return circle;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/circle.js","import noop from \"../noop.js\";\n\nexport default function() {\n var lines = [],\n line;\n return {\n point: function(x, y, m) {\n line.push([x, y, m]);\n },\n lineStart: function() {\n lines.push(line = []);\n },\n lineEnd: noop,\n rejoin: function() {\n if (lines.length > 1) lines.push(lines.pop().concat(lines.shift()));\n },\n result: function() {\n var result = lines;\n lines = [];\n line = null;\n return result;\n }\n };\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/buffer.js","import {abs, epsilon} from \"./math.js\";\n\nexport default function(a, b) {\n return abs(a[0] - b[0]) < epsilon && abs(a[1] - b[1]) < epsilon;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/pointEqual.js","import pointEqual from \"../pointEqual.js\";\nimport {epsilon} from \"../math.js\";\n\nfunction Intersection(point, points, other, entry) {\n this.x = point;\n this.z = points;\n this.o = other; // another intersection\n this.e = entry; // is an entry?\n this.v = false; // visited\n this.n = this.p = null; // next & previous\n}\n\n// A generalized polygon clipping algorithm: given a polygon that has been cut\n// into its visible line segments, and rejoins the segments by interpolating\n// along the clip edge.\nexport default function(segments, compareIntersection, startInside, interpolate, stream) {\n var subject = [],\n clip = [],\n i,\n n;\n\n segments.forEach(function(segment) {\n if ((n = segment.length - 1) <= 0) return;\n var n, p0 = segment[0], p1 = segment[n], x;\n\n if (pointEqual(p0, p1)) {\n if (!p0[2] && !p1[2]) {\n stream.lineStart();\n for (i = 0; i < n; ++i) stream.point((p0 = segment[i])[0], p0[1]);\n stream.lineEnd();\n return;\n }\n // handle degenerate cases by moving the point\n p1[0] += 2 * epsilon;\n }\n\n subject.push(x = new Intersection(p0, segment, null, true));\n clip.push(x.o = new Intersection(p0, null, x, false));\n subject.push(x = new Intersection(p1, segment, null, false));\n clip.push(x.o = new Intersection(p1, null, x, true));\n });\n\n if (!subject.length) return;\n\n clip.sort(compareIntersection);\n link(subject);\n link(clip);\n\n for (i = 0, n = clip.length; i < n; ++i) {\n clip[i].e = startInside = !startInside;\n }\n\n var start = subject[0],\n points,\n point;\n\n while (1) {\n // Find first unvisited intersection.\n var current = start,\n isSubject = true;\n while (current.v) if ((current = current.n) === start) return;\n points = current.z;\n stream.lineStart();\n do {\n current.v = current.o.v = true;\n if (current.e) {\n if (isSubject) {\n for (i = 0, n = points.length; i < n; ++i) stream.point((point = points[i])[0], point[1]);\n } else {\n interpolate(current.x, current.n.x, 1, stream);\n }\n current = current.n;\n } else {\n if (isSubject) {\n points = current.p.z;\n for (i = points.length - 1; i >= 0; --i) stream.point((point = points[i])[0], point[1]);\n } else {\n interpolate(current.x, current.p.x, -1, stream);\n }\n current = current.p;\n }\n current = current.o;\n points = current.z;\n isSubject = !isSubject;\n } while (!current.v);\n stream.lineEnd();\n }\n}\n\nfunction link(array) {\n if (!(n = array.length)) return;\n var n,\n i = 0,\n a = array[0],\n b;\n while (++i < n) {\n a.n = b = array[i];\n b.p = a;\n a = b;\n }\n a.n = b = array[0];\n b.p = a;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/rejoin.js","import {Adder} from \"d3-array\";\nimport {cartesian, cartesianCross, cartesianNormalizeInPlace} from \"./cartesian.js\";\nimport {abs, asin, atan2, cos, epsilon, epsilon2, halfPi, pi, quarterPi, sign, sin, tau} from \"./math.js\";\n\nfunction longitude(point) {\n if (abs(point[0]) <= pi)\n return point[0];\n else\n return sign(point[0]) * ((abs(point[0]) + pi) % tau - pi);\n}\n\nexport default function(polygon, point) {\n var lambda = longitude(point),\n phi = point[1],\n sinPhi = sin(phi),\n normal = [sin(lambda), -cos(lambda), 0],\n angle = 0,\n winding = 0;\n\n var sum = new Adder();\n\n if (sinPhi === 1) phi = halfPi + epsilon;\n else if (sinPhi === -1) phi = -halfPi - epsilon;\n\n for (var i = 0, n = polygon.length; i < n; ++i) {\n if (!(m = (ring = polygon[i]).length)) continue;\n var ring,\n m,\n point0 = ring[m - 1],\n lambda0 = longitude(point0),\n phi0 = point0[1] / 2 + quarterPi,\n sinPhi0 = sin(phi0),\n cosPhi0 = cos(phi0);\n\n for (var j = 0; j < m; ++j, lambda0 = lambda1, sinPhi0 = sinPhi1, cosPhi0 = cosPhi1, point0 = point1) {\n var point1 = ring[j],\n lambda1 = longitude(point1),\n phi1 = point1[1] / 2 + quarterPi,\n sinPhi1 = sin(phi1),\n cosPhi1 = cos(phi1),\n delta = lambda1 - lambda0,\n sign = delta >= 0 ? 1 : -1,\n absDelta = sign * delta,\n antimeridian = absDelta > pi,\n k = sinPhi0 * sinPhi1;\n\n sum.add(atan2(k * sign * sin(absDelta), cosPhi0 * cosPhi1 + k * cos(absDelta)));\n angle += antimeridian ? delta + sign * tau : delta;\n\n // Are the longitudes either side of the point’s meridian (lambda),\n // and are the latitudes smaller than the parallel (phi)?\n if (antimeridian ^ lambda0 >= lambda ^ lambda1 >= lambda) {\n var arc = cartesianCross(cartesian(point0), cartesian(point1));\n cartesianNormalizeInPlace(arc);\n var intersection = cartesianCross(normal, arc);\n cartesianNormalizeInPlace(intersection);\n var phiArc = (antimeridian ^ delta >= 0 ? -1 : 1) * asin(intersection[2]);\n if (phi > phiArc || phi === phiArc && (arc[0] || arc[1])) {\n winding += antimeridian ^ delta >= 0 ? 1 : -1;\n }\n }\n }\n }\n\n // First, determine whether the South pole is inside or outside:\n //\n // It is inside if:\n // * the polygon winds around it in a clockwise direction.\n // * the polygon does not (cumulatively) wind around it, but has a negative\n // (counter-clockwise) area.\n //\n // Second, count the (signed) number of times a segment crosses a lambda\n // from the point to the South pole. If it is zero, then the point is the\n // same side as the South pole.\n\n return (angle < -epsilon || angle < epsilon && sum < -epsilon2) ^ (winding & 1);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/polygonContains.js","import clipBuffer from \"./buffer.js\";\nimport clipRejoin from \"./rejoin.js\";\nimport {epsilon, halfPi} from \"../math.js\";\nimport polygonContains from \"../polygonContains.js\";\nimport {merge} from \"d3-array\";\n\nexport default function(pointVisible, clipLine, interpolate, start) {\n return function(sink) {\n var line = clipLine(sink),\n ringBuffer = clipBuffer(),\n ringSink = clipLine(ringBuffer),\n polygonStarted = false,\n polygon,\n segments,\n ring;\n\n var clip = {\n point: point,\n lineStart: lineStart,\n lineEnd: lineEnd,\n polygonStart: function() {\n clip.point = pointRing;\n clip.lineStart = ringStart;\n clip.lineEnd = ringEnd;\n segments = [];\n polygon = [];\n },\n polygonEnd: function() {\n clip.point = point;\n clip.lineStart = lineStart;\n clip.lineEnd = lineEnd;\n segments = merge(segments);\n var startInside = polygonContains(polygon, start);\n if (segments.length) {\n if (!polygonStarted) sink.polygonStart(), polygonStarted = true;\n clipRejoin(segments, compareIntersection, startInside, interpolate, sink);\n } else if (startInside) {\n if (!polygonStarted) sink.polygonStart(), polygonStarted = true;\n sink.lineStart();\n interpolate(null, null, 1, sink);\n sink.lineEnd();\n }\n if (polygonStarted) sink.polygonEnd(), polygonStarted = false;\n segments = polygon = null;\n },\n sphere: function() {\n sink.polygonStart();\n sink.lineStart();\n interpolate(null, null, 1, sink);\n sink.lineEnd();\n sink.polygonEnd();\n }\n };\n\n function point(lambda, phi) {\n if (pointVisible(lambda, phi)) sink.point(lambda, phi);\n }\n\n function pointLine(lambda, phi) {\n line.point(lambda, phi);\n }\n\n function lineStart() {\n clip.point = pointLine;\n line.lineStart();\n }\n\n function lineEnd() {\n clip.point = point;\n line.lineEnd();\n }\n\n function pointRing(lambda, phi) {\n ring.push([lambda, phi]);\n ringSink.point(lambda, phi);\n }\n\n function ringStart() {\n ringSink.lineStart();\n ring = [];\n }\n\n function ringEnd() {\n pointRing(ring[0][0], ring[0][1]);\n ringSink.lineEnd();\n\n var clean = ringSink.clean(),\n ringSegments = ringBuffer.result(),\n i, n = ringSegments.length, m,\n segment,\n point;\n\n ring.pop();\n polygon.push(ring);\n ring = null;\n\n if (!n) return;\n\n // No intersections.\n if (clean & 1) {\n segment = ringSegments[0];\n if ((m = segment.length - 1) > 0) {\n if (!polygonStarted) sink.polygonStart(), polygonStarted = true;\n sink.lineStart();\n for (i = 0; i < m; ++i) sink.point((point = segment[i])[0], point[1]);\n sink.lineEnd();\n }\n return;\n }\n\n // Rejoin connected segments.\n // TODO reuse ringBuffer.rejoin()?\n if (n > 1 && clean & 2) ringSegments.push(ringSegments.pop().concat(ringSegments.shift()));\n\n segments.push(ringSegments.filter(validSegment));\n }\n\n return clip;\n };\n}\n\nfunction validSegment(segment) {\n return segment.length > 1;\n}\n\n// Intersections are sorted along the clip edge. For both antimeridian cutting\n// and circle clipping, the same comparison is used.\nfunction compareIntersection(a, b) {\n return ((a = a.x)[0] < 0 ? a[1] - halfPi - epsilon : halfPi - a[1])\n - ((b = b.x)[0] < 0 ? b[1] - halfPi - epsilon : halfPi - b[1]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/index.js","import clip from \"./index.js\";\nimport {abs, atan, cos, epsilon, halfPi, pi, sin} from \"../math.js\";\n\nexport default clip(\n function() { return true; },\n clipAntimeridianLine,\n clipAntimeridianInterpolate,\n [-pi, -halfPi]\n);\n\n// Takes a line and cuts into visible segments. Return values: 0 - there were\n// intersections or the line was empty; 1 - no intersections; 2 - there were\n// intersections, and the first and last segments should be rejoined.\nfunction clipAntimeridianLine(stream) {\n var lambda0 = NaN,\n phi0 = NaN,\n sign0 = NaN,\n clean; // no intersections\n\n return {\n lineStart: function() {\n stream.lineStart();\n clean = 1;\n },\n point: function(lambda1, phi1) {\n var sign1 = lambda1 > 0 ? pi : -pi,\n delta = abs(lambda1 - lambda0);\n if (abs(delta - pi) < epsilon) { // line crosses a pole\n stream.point(lambda0, phi0 = (phi0 + phi1) / 2 > 0 ? halfPi : -halfPi);\n stream.point(sign0, phi0);\n stream.lineEnd();\n stream.lineStart();\n stream.point(sign1, phi0);\n stream.point(lambda1, phi0);\n clean = 0;\n } else if (sign0 !== sign1 && delta >= pi) { // line crosses antimeridian\n if (abs(lambda0 - sign0) < epsilon) lambda0 -= sign0 * epsilon; // handle degeneracies\n if (abs(lambda1 - sign1) < epsilon) lambda1 -= sign1 * epsilon;\n phi0 = clipAntimeridianIntersect(lambda0, phi0, lambda1, phi1);\n stream.point(sign0, phi0);\n stream.lineEnd();\n stream.lineStart();\n stream.point(sign1, phi0);\n clean = 0;\n }\n stream.point(lambda0 = lambda1, phi0 = phi1);\n sign0 = sign1;\n },\n lineEnd: function() {\n stream.lineEnd();\n lambda0 = phi0 = NaN;\n },\n clean: function() {\n return 2 - clean; // if intersections, rejoin first and last segments\n }\n };\n}\n\nfunction clipAntimeridianIntersect(lambda0, phi0, lambda1, phi1) {\n var cosPhi0,\n cosPhi1,\n sinLambda0Lambda1 = sin(lambda0 - lambda1);\n return abs(sinLambda0Lambda1) > epsilon\n ? atan((sin(phi0) * (cosPhi1 = cos(phi1)) * sin(lambda1)\n - sin(phi1) * (cosPhi0 = cos(phi0)) * sin(lambda0))\n / (cosPhi0 * cosPhi1 * sinLambda0Lambda1))\n : (phi0 + phi1) / 2;\n}\n\nfunction clipAntimeridianInterpolate(from, to, direction, stream) {\n var phi;\n if (from == null) {\n phi = direction * halfPi;\n stream.point(-pi, phi);\n stream.point(0, phi);\n stream.point(pi, phi);\n stream.point(pi, 0);\n stream.point(pi, -phi);\n stream.point(0, -phi);\n stream.point(-pi, -phi);\n stream.point(-pi, 0);\n stream.point(-pi, phi);\n } else if (abs(from[0] - to[0]) > epsilon) {\n var lambda = from[0] < to[0] ? pi : -pi;\n phi = direction * lambda / 2;\n stream.point(-lambda, phi);\n stream.point(0, phi);\n stream.point(lambda, phi);\n } else {\n stream.point(to[0], to[1]);\n }\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/antimeridian.js","import {cartesian, cartesianAddInPlace, cartesianCross, cartesianDot, cartesianScale, spherical} from \"../cartesian.js\";\nimport {circleStream} from \"../circle.js\";\nimport {abs, cos, epsilon, pi, radians, sqrt} from \"../math.js\";\nimport pointEqual from \"../pointEqual.js\";\nimport clip from \"./index.js\";\n\nexport default function(radius) {\n var cr = cos(radius),\n delta = 6 * radians,\n smallRadius = cr > 0,\n notHemisphere = abs(cr) > epsilon; // TODO optimise for this common case\n\n function interpolate(from, to, direction, stream) {\n circleStream(stream, radius, delta, direction, from, to);\n }\n\n function visible(lambda, phi) {\n return cos(lambda) * cos(phi) > cr;\n }\n\n // Takes a line and cuts into visible segments. Return values used for polygon\n // clipping: 0 - there were intersections or the line was empty; 1 - no\n // intersections 2 - there were intersections, and the first and last segments\n // should be rejoined.\n function clipLine(stream) {\n var point0, // previous point\n c0, // code for previous point\n v0, // visibility of previous point\n v00, // visibility of first point\n clean; // no intersections\n return {\n lineStart: function() {\n v00 = v0 = false;\n clean = 1;\n },\n point: function(lambda, phi) {\n var point1 = [lambda, phi],\n point2,\n v = visible(lambda, phi),\n c = smallRadius\n ? v ? 0 : code(lambda, phi)\n : v ? code(lambda + (lambda < 0 ? pi : -pi), phi) : 0;\n if (!point0 && (v00 = v0 = v)) stream.lineStart();\n if (v !== v0) {\n point2 = intersect(point0, point1);\n if (!point2 || pointEqual(point0, point2) || pointEqual(point1, point2))\n point1[2] = 1;\n }\n if (v !== v0) {\n clean = 0;\n if (v) {\n // outside going in\n stream.lineStart();\n point2 = intersect(point1, point0);\n stream.point(point2[0], point2[1]);\n } else {\n // inside going out\n point2 = intersect(point0, point1);\n stream.point(point2[0], point2[1], 2);\n stream.lineEnd();\n }\n point0 = point2;\n } else if (notHemisphere && point0 && smallRadius ^ v) {\n var t;\n // If the codes for two points are different, or are both zero,\n // and there this segment intersects with the small circle.\n if (!(c & c0) && (t = intersect(point1, point0, true))) {\n clean = 0;\n if (smallRadius) {\n stream.lineStart();\n stream.point(t[0][0], t[0][1]);\n stream.point(t[1][0], t[1][1]);\n stream.lineEnd();\n } else {\n stream.point(t[1][0], t[1][1]);\n stream.lineEnd();\n stream.lineStart();\n stream.point(t[0][0], t[0][1], 3);\n }\n }\n }\n if (v && (!point0 || !pointEqual(point0, point1))) {\n stream.point(point1[0], point1[1]);\n }\n point0 = point1, v0 = v, c0 = c;\n },\n lineEnd: function() {\n if (v0) stream.lineEnd();\n point0 = null;\n },\n // Rejoin first and last segments if there were intersections and the first\n // and last points were visible.\n clean: function() {\n return clean | ((v00 && v0) << 1);\n }\n };\n }\n\n // Intersects the great circle between a and b with the clip circle.\n function intersect(a, b, two) {\n var pa = cartesian(a),\n pb = cartesian(b);\n\n // We have two planes, n1.p = d1 and n2.p = d2.\n // Find intersection line p(t) = c1 n1 + c2 n2 + t (n1 ⨯ n2).\n var n1 = [1, 0, 0], // normal\n n2 = cartesianCross(pa, pb),\n n2n2 = cartesianDot(n2, n2),\n n1n2 = n2[0], // cartesianDot(n1, n2),\n determinant = n2n2 - n1n2 * n1n2;\n\n // Two polar points.\n if (!determinant) return !two && a;\n\n var c1 = cr * n2n2 / determinant,\n c2 = -cr * n1n2 / determinant,\n n1xn2 = cartesianCross(n1, n2),\n A = cartesianScale(n1, c1),\n B = cartesianScale(n2, c2);\n cartesianAddInPlace(A, B);\n\n // Solve |p(t)|^2 = 1.\n var u = n1xn2,\n w = cartesianDot(A, u),\n uu = cartesianDot(u, u),\n t2 = w * w - uu * (cartesianDot(A, A) - 1);\n\n if (t2 < 0) return;\n\n var t = sqrt(t2),\n q = cartesianScale(u, (-w - t) / uu);\n cartesianAddInPlace(q, A);\n q = spherical(q);\n\n if (!two) return q;\n\n // Two intersection points.\n var lambda0 = a[0],\n lambda1 = b[0],\n phi0 = a[1],\n phi1 = b[1],\n z;\n\n if (lambda1 < lambda0) z = lambda0, lambda0 = lambda1, lambda1 = z;\n\n var delta = lambda1 - lambda0,\n polar = abs(delta - pi) < epsilon,\n meridian = polar || delta < epsilon;\n\n if (!polar && phi1 < phi0) z = phi0, phi0 = phi1, phi1 = z;\n\n // Check that the first point is between a and b.\n if (meridian\n ? polar\n ? phi0 + phi1 > 0 ^ q[1] < (abs(q[0] - lambda0) < epsilon ? phi0 : phi1)\n : phi0 <= q[1] && q[1] <= phi1\n : delta > pi ^ (lambda0 <= q[0] && q[0] <= lambda1)) {\n var q1 = cartesianScale(u, (-w + t) / uu);\n cartesianAddInPlace(q1, A);\n return [q, spherical(q1)];\n }\n }\n\n // Generates a 4-bit vector representing the location of a point relative to\n // the small circle's bounding box.\n function code(lambda, phi) {\n var r = smallRadius ? radius : pi - radius,\n code = 0;\n if (lambda < -r) code |= 1; // left\n else if (lambda > r) code |= 2; // right\n if (phi < -r) code |= 4; // below\n else if (phi > r) code |= 8; // above\n return code;\n }\n\n return clip(visible, clipLine, interpolate, smallRadius ? [0, -radius] : [-pi, radius - pi]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/circle.js","export default function(a, b, x0, y0, x1, y1) {\n var ax = a[0],\n ay = a[1],\n bx = b[0],\n by = b[1],\n t0 = 0,\n t1 = 1,\n dx = bx - ax,\n dy = by - ay,\n r;\n\n r = x0 - ax;\n if (!dx && r > 0) return;\n r /= dx;\n if (dx < 0) {\n if (r < t0) return;\n if (r < t1) t1 = r;\n } else if (dx > 0) {\n if (r > t1) return;\n if (r > t0) t0 = r;\n }\n\n r = x1 - ax;\n if (!dx && r < 0) return;\n r /= dx;\n if (dx < 0) {\n if (r > t1) return;\n if (r > t0) t0 = r;\n } else if (dx > 0) {\n if (r < t0) return;\n if (r < t1) t1 = r;\n }\n\n r = y0 - ay;\n if (!dy && r > 0) return;\n r /= dy;\n if (dy < 0) {\n if (r < t0) return;\n if (r < t1) t1 = r;\n } else if (dy > 0) {\n if (r > t1) return;\n if (r > t0) t0 = r;\n }\n\n r = y1 - ay;\n if (!dy && r < 0) return;\n r /= dy;\n if (dy < 0) {\n if (r > t1) return;\n if (r > t0) t0 = r;\n } else if (dy > 0) {\n if (r < t0) return;\n if (r < t1) t1 = r;\n }\n\n if (t0 > 0) a[0] = ax + t0 * dx, a[1] = ay + t0 * dy;\n if (t1 < 1) b[0] = ax + t1 * dx, b[1] = ay + t1 * dy;\n return true;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/line.js","import {abs, epsilon} from \"../math.js\";\nimport clipBuffer from \"./buffer.js\";\nimport clipLine from \"./line.js\";\nimport clipRejoin from \"./rejoin.js\";\nimport {merge} from \"d3-array\";\n\nvar clipMax = 1e9, clipMin = -clipMax;\n\n// TODO Use d3-polygon’s polygonContains here for the ring check?\n// TODO Eliminate duplicate buffering in clipBuffer and polygon.push?\n\nexport default function clipRectangle(x0, y0, x1, y1) {\n\n function visible(x, y) {\n return x0 <= x && x <= x1 && y0 <= y && y <= y1;\n }\n\n function interpolate(from, to, direction, stream) {\n var a = 0, a1 = 0;\n if (from == null\n || (a = corner(from, direction)) !== (a1 = corner(to, direction))\n || comparePoint(from, to) < 0 ^ direction > 0) {\n do stream.point(a === 0 || a === 3 ? x0 : x1, a > 1 ? y1 : y0);\n while ((a = (a + direction + 4) % 4) !== a1);\n } else {\n stream.point(to[0], to[1]);\n }\n }\n\n function corner(p, direction) {\n return abs(p[0] - x0) < epsilon ? direction > 0 ? 0 : 3\n : abs(p[0] - x1) < epsilon ? direction > 0 ? 2 : 1\n : abs(p[1] - y0) < epsilon ? direction > 0 ? 1 : 0\n : direction > 0 ? 3 : 2; // abs(p[1] - y1) < epsilon\n }\n\n function compareIntersection(a, b) {\n return comparePoint(a.x, b.x);\n }\n\n function comparePoint(a, b) {\n var ca = corner(a, 1),\n cb = corner(b, 1);\n return ca !== cb ? ca - cb\n : ca === 0 ? b[1] - a[1]\n : ca === 1 ? a[0] - b[0]\n : ca === 2 ? a[1] - b[1]\n : b[0] - a[0];\n }\n\n return function(stream) {\n var activeStream = stream,\n bufferStream = clipBuffer(),\n segments,\n polygon,\n ring,\n x__, y__, v__, // first point\n x_, y_, v_, // previous point\n first,\n clean;\n\n var clipStream = {\n point: point,\n lineStart: lineStart,\n lineEnd: lineEnd,\n polygonStart: polygonStart,\n polygonEnd: polygonEnd\n };\n\n function point(x, y) {\n if (visible(x, y)) activeStream.point(x, y);\n }\n\n function polygonInside() {\n var winding = 0;\n\n for (var i = 0, n = polygon.length; i < n; ++i) {\n for (var ring = polygon[i], j = 1, m = ring.length, point = ring[0], a0, a1, b0 = point[0], b1 = point[1]; j < m; ++j) {\n a0 = b0, a1 = b1, point = ring[j], b0 = point[0], b1 = point[1];\n if (a1 <= y1) { if (b1 > y1 && (b0 - a0) * (y1 - a1) > (b1 - a1) * (x0 - a0)) ++winding; }\n else { if (b1 <= y1 && (b0 - a0) * (y1 - a1) < (b1 - a1) * (x0 - a0)) --winding; }\n }\n }\n\n return winding;\n }\n\n // Buffer geometry within a polygon and then clip it en masse.\n function polygonStart() {\n activeStream = bufferStream, segments = [], polygon = [], clean = true;\n }\n\n function polygonEnd() {\n var startInside = polygonInside(),\n cleanInside = clean && startInside,\n visible = (segments = merge(segments)).length;\n if (cleanInside || visible) {\n stream.polygonStart();\n if (cleanInside) {\n stream.lineStart();\n interpolate(null, null, 1, stream);\n stream.lineEnd();\n }\n if (visible) {\n clipRejoin(segments, compareIntersection, startInside, interpolate, stream);\n }\n stream.polygonEnd();\n }\n activeStream = stream, segments = polygon = ring = null;\n }\n\n function lineStart() {\n clipStream.point = linePoint;\n if (polygon) polygon.push(ring = []);\n first = true;\n v_ = false;\n x_ = y_ = NaN;\n }\n\n // TODO rather than special-case polygons, simply handle them separately.\n // Ideally, coincident intersection points should be jittered to avoid\n // clipping issues.\n function lineEnd() {\n if (segments) {\n linePoint(x__, y__);\n if (v__ && v_) bufferStream.rejoin();\n segments.push(bufferStream.result());\n }\n clipStream.point = point;\n if (v_) activeStream.lineEnd();\n }\n\n function linePoint(x, y) {\n var v = visible(x, y);\n if (polygon) ring.push([x, y]);\n if (first) {\n x__ = x, y__ = y, v__ = v;\n first = false;\n if (v) {\n activeStream.lineStart();\n activeStream.point(x, y);\n }\n } else {\n if (v && v_) activeStream.point(x, y);\n else {\n var a = [x_ = Math.max(clipMin, Math.min(clipMax, x_)), y_ = Math.max(clipMin, Math.min(clipMax, y_))],\n b = [x = Math.max(clipMin, Math.min(clipMax, x)), y = Math.max(clipMin, Math.min(clipMax, y))];\n if (clipLine(a, b, x0, y0, x1, y1)) {\n if (!v_) {\n activeStream.lineStart();\n activeStream.point(a[0], a[1]);\n }\n activeStream.point(b[0], b[1]);\n if (!v) activeStream.lineEnd();\n clean = false;\n } else if (v) {\n activeStream.lineStart();\n activeStream.point(x, y);\n clean = false;\n }\n }\n }\n x_ = x, y_ = y, v_ = v;\n }\n\n return clipStream;\n };\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/rectangle.js","import clipRectangle from \"./rectangle.js\";\n\nexport default function() {\n var x0 = 0,\n y0 = 0,\n x1 = 960,\n y1 = 500,\n cache,\n cacheStream,\n clip;\n\n return clip = {\n stream: function(stream) {\n return cache && cacheStream === stream ? cache : cache = clipRectangle(x0, y0, x1, y1)(cacheStream = stream);\n },\n extent: function(_) {\n return arguments.length ? (x0 = +_[0][0], y0 = +_[0][1], x1 = +_[1][0], y1 = +_[1][1], cache = cacheStream = null, clip) : [[x0, y0], [x1, y1]];\n }\n };\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/clip/extent.js","import {Adder} from \"d3-array\";\nimport {abs, atan2, cos, radians, sin, sqrt} from \"./math.js\";\nimport noop from \"./noop.js\";\nimport stream from \"./stream.js\";\n\nvar lengthSum,\n lambda0,\n sinPhi0,\n cosPhi0;\n\nvar lengthStream = {\n sphere: noop,\n point: noop,\n lineStart: lengthLineStart,\n lineEnd: noop,\n polygonStart: noop,\n polygonEnd: noop\n};\n\nfunction lengthLineStart() {\n lengthStream.point = lengthPointFirst;\n lengthStream.lineEnd = lengthLineEnd;\n}\n\nfunction lengthLineEnd() {\n lengthStream.point = lengthStream.lineEnd = noop;\n}\n\nfunction lengthPointFirst(lambda, phi) {\n lambda *= radians, phi *= radians;\n lambda0 = lambda, sinPhi0 = sin(phi), cosPhi0 = cos(phi);\n lengthStream.point = lengthPoint;\n}\n\nfunction lengthPoint(lambda, phi) {\n lambda *= radians, phi *= radians;\n var sinPhi = sin(phi),\n cosPhi = cos(phi),\n delta = abs(lambda - lambda0),\n cosDelta = cos(delta),\n sinDelta = sin(delta),\n x = cosPhi * sinDelta,\n y = cosPhi0 * sinPhi - sinPhi0 * cosPhi * cosDelta,\n z = sinPhi0 * sinPhi + cosPhi0 * cosPhi * cosDelta;\n lengthSum.add(atan2(sqrt(x * x + y * y), z));\n lambda0 = lambda, sinPhi0 = sinPhi, cosPhi0 = cosPhi;\n}\n\nexport default function(object) {\n lengthSum = new Adder();\n stream(object, lengthStream);\n return +lengthSum;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/length.js","import length from \"./length.js\";\n\nvar coordinates = [null, null],\n object = {type: \"LineString\", coordinates: coordinates};\n\nexport default function(a, b) {\n coordinates[0] = a;\n coordinates[1] = b;\n return length(object);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/distance.js","import {default as polygonContains} from \"./polygonContains.js\";\nimport {default as distance} from \"./distance.js\";\nimport {epsilon2, radians} from \"./math.js\";\n\nvar containsObjectType = {\n Feature: function(object, point) {\n return containsGeometry(object.geometry, point);\n },\n FeatureCollection: function(object, point) {\n var features = object.features, i = -1, n = features.length;\n while (++i < n) if (containsGeometry(features[i].geometry, point)) return true;\n return false;\n }\n};\n\nvar containsGeometryType = {\n Sphere: function() {\n return true;\n },\n Point: function(object, point) {\n return containsPoint(object.coordinates, point);\n },\n MultiPoint: function(object, point) {\n var coordinates = object.coordinates, i = -1, n = coordinates.length;\n while (++i < n) if (containsPoint(coordinates[i], point)) return true;\n return false;\n },\n LineString: function(object, point) {\n return containsLine(object.coordinates, point);\n },\n MultiLineString: function(object, point) {\n var coordinates = object.coordinates, i = -1, n = coordinates.length;\n while (++i < n) if (containsLine(coordinates[i], point)) return true;\n return false;\n },\n Polygon: function(object, point) {\n return containsPolygon(object.coordinates, point);\n },\n MultiPolygon: function(object, point) {\n var coordinates = object.coordinates, i = -1, n = coordinates.length;\n while (++i < n) if (containsPolygon(coordinates[i], point)) return true;\n return false;\n },\n GeometryCollection: function(object, point) {\n var geometries = object.geometries, i = -1, n = geometries.length;\n while (++i < n) if (containsGeometry(geometries[i], point)) return true;\n return false;\n }\n};\n\nfunction containsGeometry(geometry, point) {\n return geometry && containsGeometryType.hasOwnProperty(geometry.type)\n ? containsGeometryType[geometry.type](geometry, point)\n : false;\n}\n\nfunction containsPoint(coordinates, point) {\n return distance(coordinates, point) === 0;\n}\n\nfunction containsLine(coordinates, point) {\n var ao, bo, ab;\n for (var i = 0, n = coordinates.length; i < n; i++) {\n bo = distance(coordinates[i], point);\n if (bo === 0) return true;\n if (i > 0) {\n ab = distance(coordinates[i], coordinates[i - 1]);\n if (\n ab > 0 &&\n ao <= ab &&\n bo <= ab &&\n (ao + bo - ab) * (1 - Math.pow((ao - bo) / ab, 2)) < epsilon2 * ab\n )\n return true;\n }\n ao = bo;\n }\n return false;\n}\n\nfunction containsPolygon(coordinates, point) {\n return !!polygonContains(coordinates.map(ringRadians), pointRadians(point));\n}\n\nfunction ringRadians(ring) {\n return ring = ring.map(pointRadians), ring.pop(), ring;\n}\n\nfunction pointRadians(point) {\n return [point[0] * radians, point[1] * radians];\n}\n\nexport default function(object, point) {\n return (object && containsObjectType.hasOwnProperty(object.type)\n ? containsObjectType[object.type]\n : containsGeometry)(object, point);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/contains.js","import {range} from \"d3-array\";\nimport {abs, ceil, epsilon} from \"./math.js\";\n\nfunction graticuleX(y0, y1, dy) {\n var y = range(y0, y1 - epsilon, dy).concat(y1);\n return function(x) { return y.map(function(y) { return [x, y]; }); };\n}\n\nfunction graticuleY(x0, x1, dx) {\n var x = range(x0, x1 - epsilon, dx).concat(x1);\n return function(y) { return x.map(function(x) { return [x, y]; }); };\n}\n\nexport default function graticule() {\n var x1, x0, X1, X0,\n y1, y0, Y1, Y0,\n dx = 10, dy = dx, DX = 90, DY = 360,\n x, y, X, Y,\n precision = 2.5;\n\n function graticule() {\n return {type: \"MultiLineString\", coordinates: lines()};\n }\n\n function lines() {\n return range(ceil(X0 / DX) * DX, X1, DX).map(X)\n .concat(range(ceil(Y0 / DY) * DY, Y1, DY).map(Y))\n .concat(range(ceil(x0 / dx) * dx, x1, dx).filter(function(x) { return abs(x % DX) > epsilon; }).map(x))\n .concat(range(ceil(y0 / dy) * dy, y1, dy).filter(function(y) { return abs(y % DY) > epsilon; }).map(y));\n }\n\n graticule.lines = function() {\n return lines().map(function(coordinates) { return {type: \"LineString\", coordinates: coordinates}; });\n };\n\n graticule.outline = function() {\n return {\n type: \"Polygon\",\n coordinates: [\n X(X0).concat(\n Y(Y1).slice(1),\n X(X1).reverse().slice(1),\n Y(Y0).reverse().slice(1))\n ]\n };\n };\n\n graticule.extent = function(_) {\n if (!arguments.length) return graticule.extentMinor();\n return graticule.extentMajor(_).extentMinor(_);\n };\n\n graticule.extentMajor = function(_) {\n if (!arguments.length) return [[X0, Y0], [X1, Y1]];\n X0 = +_[0][0], X1 = +_[1][0];\n Y0 = +_[0][1], Y1 = +_[1][1];\n if (X0 > X1) _ = X0, X0 = X1, X1 = _;\n if (Y0 > Y1) _ = Y0, Y0 = Y1, Y1 = _;\n return graticule.precision(precision);\n };\n\n graticule.extentMinor = function(_) {\n if (!arguments.length) return [[x0, y0], [x1, y1]];\n x0 = +_[0][0], x1 = +_[1][0];\n y0 = +_[0][1], y1 = +_[1][1];\n if (x0 > x1) _ = x0, x0 = x1, x1 = _;\n if (y0 > y1) _ = y0, y0 = y1, y1 = _;\n return graticule.precision(precision);\n };\n\n graticule.step = function(_) {\n if (!arguments.length) return graticule.stepMinor();\n return graticule.stepMajor(_).stepMinor(_);\n };\n\n graticule.stepMajor = function(_) {\n if (!arguments.length) return [DX, DY];\n DX = +_[0], DY = +_[1];\n return graticule;\n };\n\n graticule.stepMinor = function(_) {\n if (!arguments.length) return [dx, dy];\n dx = +_[0], dy = +_[1];\n return graticule;\n };\n\n graticule.precision = function(_) {\n if (!arguments.length) return precision;\n precision = +_;\n x = graticuleX(y0, y1, 90);\n y = graticuleY(x0, x1, precision);\n X = graticuleX(Y0, Y1, 90);\n Y = graticuleY(X0, X1, precision);\n return graticule;\n };\n\n return graticule\n .extentMajor([[-180, -90 + epsilon], [180, 90 - epsilon]])\n .extentMinor([[-180, -80 - epsilon], [180, 80 + epsilon]]);\n}\n\nexport function graticule10() {\n return graticule()();\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/graticule.js","import {asin, atan2, cos, degrees, haversin, radians, sin, sqrt} from \"./math.js\";\n\nexport default function(a, b) {\n var x0 = a[0] * radians,\n y0 = a[1] * radians,\n x1 = b[0] * radians,\n y1 = b[1] * radians,\n cy0 = cos(y0),\n sy0 = sin(y0),\n cy1 = cos(y1),\n sy1 = sin(y1),\n kx0 = cy0 * cos(x0),\n ky0 = cy0 * sin(x0),\n kx1 = cy1 * cos(x1),\n ky1 = cy1 * sin(x1),\n d = 2 * asin(sqrt(haversin(y1 - y0) + cy0 * cy1 * haversin(x1 - x0))),\n k = sin(d);\n\n var interpolate = d ? function(t) {\n var B = sin(t *= d) / k,\n A = sin(d - t) / k,\n x = A * kx0 + B * kx1,\n y = A * ky0 + B * ky1,\n z = A * sy0 + B * sy1;\n return [\n atan2(y, x) * degrees,\n atan2(z, sqrt(x * x + y * y)) * degrees\n ];\n } : function() {\n return [x0 * degrees, y0 * degrees];\n };\n\n interpolate.distance = d;\n\n return interpolate;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/interpolate.js","import {Adder} from \"d3-array\";\nimport {abs} from \"../math.js\";\nimport noop from \"../noop.js\";\n\nvar areaSum = new Adder(),\n areaRingSum = new Adder(),\n x00,\n y00,\n x0,\n y0;\n\nvar areaStream = {\n point: noop,\n lineStart: noop,\n lineEnd: noop,\n polygonStart: function() {\n areaStream.lineStart = areaRingStart;\n areaStream.lineEnd = areaRingEnd;\n },\n polygonEnd: function() {\n areaStream.lineStart = areaStream.lineEnd = areaStream.point = noop;\n areaSum.add(abs(areaRingSum));\n areaRingSum = new Adder();\n },\n result: function() {\n var area = areaSum / 2;\n areaSum = new Adder();\n return area;\n }\n};\n\nfunction areaRingStart() {\n areaStream.point = areaPointFirst;\n}\n\nfunction areaPointFirst(x, y) {\n areaStream.point = areaPoint;\n x00 = x0 = x, y00 = y0 = y;\n}\n\nfunction areaPoint(x, y) {\n areaRingSum.add(y0 * x - x0 * y);\n x0 = x, y0 = y;\n}\n\nfunction areaRingEnd() {\n areaPoint(x00, y00);\n}\n\nexport default areaStream;\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/area.js","export default x => x;\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/identity.js","import noop from \"../noop.js\";\n\nvar x0 = Infinity,\n y0 = x0,\n x1 = -x0,\n y1 = x1;\n\nvar boundsStream = {\n point: boundsPoint,\n lineStart: noop,\n lineEnd: noop,\n polygonStart: noop,\n polygonEnd: noop,\n result: function() {\n var bounds = [[x0, y0], [x1, y1]];\n x1 = y1 = -(y0 = x0 = Infinity);\n return bounds;\n }\n};\n\nfunction boundsPoint(x, y) {\n if (x < x0) x0 = x;\n if (x > x1) x1 = x;\n if (y < y0) y0 = y;\n if (y > y1) y1 = y;\n}\n\nexport default boundsStream;\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/bounds.js","import {sqrt} from \"../math.js\";\n\n// TODO Enforce positive area for exterior, negative area for interior?\n\nvar X0 = 0,\n Y0 = 0,\n Z0 = 0,\n X1 = 0,\n Y1 = 0,\n Z1 = 0,\n X2 = 0,\n Y2 = 0,\n Z2 = 0,\n x00,\n y00,\n x0,\n y0;\n\nvar centroidStream = {\n point: centroidPoint,\n lineStart: centroidLineStart,\n lineEnd: centroidLineEnd,\n polygonStart: function() {\n centroidStream.lineStart = centroidRingStart;\n centroidStream.lineEnd = centroidRingEnd;\n },\n polygonEnd: function() {\n centroidStream.point = centroidPoint;\n centroidStream.lineStart = centroidLineStart;\n centroidStream.lineEnd = centroidLineEnd;\n },\n result: function() {\n var centroid = Z2 ? [X2 / Z2, Y2 / Z2]\n : Z1 ? [X1 / Z1, Y1 / Z1]\n : Z0 ? [X0 / Z0, Y0 / Z0]\n : [NaN, NaN];\n X0 = Y0 = Z0 =\n X1 = Y1 = Z1 =\n X2 = Y2 = Z2 = 0;\n return centroid;\n }\n};\n\nfunction centroidPoint(x, y) {\n X0 += x;\n Y0 += y;\n ++Z0;\n}\n\nfunction centroidLineStart() {\n centroidStream.point = centroidPointFirstLine;\n}\n\nfunction centroidPointFirstLine(x, y) {\n centroidStream.point = centroidPointLine;\n centroidPoint(x0 = x, y0 = y);\n}\n\nfunction centroidPointLine(x, y) {\n var dx = x - x0, dy = y - y0, z = sqrt(dx * dx + dy * dy);\n X1 += z * (x0 + x) / 2;\n Y1 += z * (y0 + y) / 2;\n Z1 += z;\n centroidPoint(x0 = x, y0 = y);\n}\n\nfunction centroidLineEnd() {\n centroidStream.point = centroidPoint;\n}\n\nfunction centroidRingStart() {\n centroidStream.point = centroidPointFirstRing;\n}\n\nfunction centroidRingEnd() {\n centroidPointRing(x00, y00);\n}\n\nfunction centroidPointFirstRing(x, y) {\n centroidStream.point = centroidPointRing;\n centroidPoint(x00 = x0 = x, y00 = y0 = y);\n}\n\nfunction centroidPointRing(x, y) {\n var dx = x - x0,\n dy = y - y0,\n z = sqrt(dx * dx + dy * dy);\n\n X1 += z * (x0 + x) / 2;\n Y1 += z * (y0 + y) / 2;\n Z1 += z;\n\n z = y0 * x - x0 * y;\n X2 += z * (x0 + x);\n Y2 += z * (y0 + y);\n Z2 += z * 3;\n centroidPoint(x0 = x, y0 = y);\n}\n\nexport default centroidStream;\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/centroid.js","import {tau} from \"../math.js\";\nimport noop from \"../noop.js\";\n\nexport default function PathContext(context) {\n this._context = context;\n}\n\nPathContext.prototype = {\n _radius: 4.5,\n pointRadius: function(_) {\n return this._radius = _, this;\n },\n polygonStart: function() {\n this._line = 0;\n },\n polygonEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line === 0) this._context.closePath();\n this._point = NaN;\n },\n point: function(x, y) {\n switch (this._point) {\n case 0: {\n this._context.moveTo(x, y);\n this._point = 1;\n break;\n }\n case 1: {\n this._context.lineTo(x, y);\n break;\n }\n default: {\n this._context.moveTo(x + this._radius, y);\n this._context.arc(x, y, this._radius, 0, tau);\n break;\n }\n }\n },\n result: noop\n};\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/context.js","import {Adder} from \"d3-array\";\nimport {sqrt} from \"../math.js\";\nimport noop from \"../noop.js\";\n\nvar lengthSum = new Adder(),\n lengthRing,\n x00,\n y00,\n x0,\n y0;\n\nvar lengthStream = {\n point: noop,\n lineStart: function() {\n lengthStream.point = lengthPointFirst;\n },\n lineEnd: function() {\n if (lengthRing) lengthPoint(x00, y00);\n lengthStream.point = noop;\n },\n polygonStart: function() {\n lengthRing = true;\n },\n polygonEnd: function() {\n lengthRing = null;\n },\n result: function() {\n var length = +lengthSum;\n lengthSum = new Adder();\n return length;\n }\n};\n\nfunction lengthPointFirst(x, y) {\n lengthStream.point = lengthPoint;\n x00 = x0 = x, y00 = y0 = y;\n}\n\nfunction lengthPoint(x, y) {\n x0 -= x, y0 -= y;\n lengthSum.add(sqrt(x0 * x0 + y0 * y0));\n x0 = x, y0 = y;\n}\n\nexport default lengthStream;\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/measure.js","export default function PathString() {\n this._string = [];\n}\n\nPathString.prototype = {\n _radius: 4.5,\n _circle: circle(4.5),\n pointRadius: function(_) {\n if ((_ = +_) !== this._radius) this._radius = _, this._circle = null;\n return this;\n },\n polygonStart: function() {\n this._line = 0;\n },\n polygonEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line === 0) this._string.push(\"Z\");\n this._point = NaN;\n },\n point: function(x, y) {\n switch (this._point) {\n case 0: {\n this._string.push(\"M\", x, \",\", y);\n this._point = 1;\n break;\n }\n case 1: {\n this._string.push(\"L\", x, \",\", y);\n break;\n }\n default: {\n if (this._circle == null) this._circle = circle(this._radius);\n this._string.push(\"M\", x, \",\", y, this._circle);\n break;\n }\n }\n },\n result: function() {\n if (this._string.length) {\n var result = this._string.join(\"\");\n this._string = [];\n return result;\n } else {\n return null;\n }\n }\n};\n\nfunction circle(radius) {\n return \"m0,\" + radius\n + \"a\" + radius + \",\" + radius + \" 0 1,1 0,\" + -2 * radius\n + \"a\" + radius + \",\" + radius + \" 0 1,1 0,\" + 2 * radius\n + \"z\";\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/string.js","import identity from \"../identity.js\";\nimport stream from \"../stream.js\";\nimport pathArea from \"./area.js\";\nimport pathBounds from \"./bounds.js\";\nimport pathCentroid from \"./centroid.js\";\nimport PathContext from \"./context.js\";\nimport pathMeasure from \"./measure.js\";\nimport PathString from \"./string.js\";\n\nexport default function(projection, context) {\n var pointRadius = 4.5,\n projectionStream,\n contextStream;\n\n function path(object) {\n if (object) {\n if (typeof pointRadius === \"function\") contextStream.pointRadius(+pointRadius.apply(this, arguments));\n stream(object, projectionStream(contextStream));\n }\n return contextStream.result();\n }\n\n path.area = function(object) {\n stream(object, projectionStream(pathArea));\n return pathArea.result();\n };\n\n path.measure = function(object) {\n stream(object, projectionStream(pathMeasure));\n return pathMeasure.result();\n };\n\n path.bounds = function(object) {\n stream(object, projectionStream(pathBounds));\n return pathBounds.result();\n };\n\n path.centroid = function(object) {\n stream(object, projectionStream(pathCentroid));\n return pathCentroid.result();\n };\n\n path.projection = function(_) {\n return arguments.length ? (projectionStream = _ == null ? (projection = null, identity) : (projection = _).stream, path) : projection;\n };\n\n path.context = function(_) {\n if (!arguments.length) return context;\n contextStream = _ == null ? (context = null, new PathString) : new PathContext(context = _);\n if (typeof pointRadius !== \"function\") contextStream.pointRadius(pointRadius);\n return path;\n };\n\n path.pointRadius = function(_) {\n if (!arguments.length) return pointRadius;\n pointRadius = typeof _ === \"function\" ? _ : (contextStream.pointRadius(+_), +_);\n return path;\n };\n\n return path.projection(projection).context(context);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/path/index.js","export default function(methods) {\n return {\n stream: transformer(methods)\n };\n}\n\nexport function transformer(methods) {\n return function(stream) {\n var s = new TransformStream;\n for (var key in methods) s[key] = methods[key];\n s.stream = stream;\n return s;\n };\n}\n\nfunction TransformStream() {}\n\nTransformStream.prototype = {\n constructor: TransformStream,\n point: function(x, y) { this.stream.point(x, y); },\n sphere: function() { this.stream.sphere(); },\n lineStart: function() { this.stream.lineStart(); },\n lineEnd: function() { this.stream.lineEnd(); },\n polygonStart: function() { this.stream.polygonStart(); },\n polygonEnd: function() { this.stream.polygonEnd(); }\n};\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/transform.js","import {default as geoStream} from \"../stream.js\";\nimport boundsStream from \"../path/bounds.js\";\n\nfunction fit(projection, fitBounds, object) {\n var clip = projection.clipExtent && projection.clipExtent();\n projection.scale(150).translate([0, 0]);\n if (clip != null) projection.clipExtent(null);\n geoStream(object, projection.stream(boundsStream));\n fitBounds(boundsStream.result());\n if (clip != null) projection.clipExtent(clip);\n return projection;\n}\n\nexport function fitExtent(projection, extent, object) {\n return fit(projection, function(b) {\n var w = extent[1][0] - extent[0][0],\n h = extent[1][1] - extent[0][1],\n k = Math.min(w / (b[1][0] - b[0][0]), h / (b[1][1] - b[0][1])),\n x = +extent[0][0] + (w - k * (b[1][0] + b[0][0])) / 2,\n y = +extent[0][1] + (h - k * (b[1][1] + b[0][1])) / 2;\n projection.scale(150 * k).translate([x, y]);\n }, object);\n}\n\nexport function fitSize(projection, size, object) {\n return fitExtent(projection, [[0, 0], size], object);\n}\n\nexport function fitWidth(projection, width, object) {\n return fit(projection, function(b) {\n var w = +width,\n k = w / (b[1][0] - b[0][0]),\n x = (w - k * (b[1][0] + b[0][0])) / 2,\n y = -k * b[0][1];\n projection.scale(150 * k).translate([x, y]);\n }, object);\n}\n\nexport function fitHeight(projection, height, object) {\n return fit(projection, function(b) {\n var h = +height,\n k = h / (b[1][1] - b[0][1]),\n x = -k * b[0][0],\n y = (h - k * (b[1][1] + b[0][1])) / 2;\n projection.scale(150 * k).translate([x, y]);\n }, object);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/fit.js","import {cartesian} from \"../cartesian.js\";\nimport {abs, asin, atan2, cos, epsilon, radians, sqrt} from \"../math.js\";\nimport {transformer} from \"../transform.js\";\n\nvar maxDepth = 16, // maximum depth of subdivision\n cosMinDistance = cos(30 * radians); // cos(minimum angular distance)\n\nexport default function(project, delta2) {\n return +delta2 ? resample(project, delta2) : resampleNone(project);\n}\n\nfunction resampleNone(project) {\n return transformer({\n point: function(x, y) {\n x = project(x, y);\n this.stream.point(x[0], x[1]);\n }\n });\n}\n\nfunction resample(project, delta2) {\n\n function resampleLineTo(x0, y0, lambda0, a0, b0, c0, x1, y1, lambda1, a1, b1, c1, depth, stream) {\n var dx = x1 - x0,\n dy = y1 - y0,\n d2 = dx * dx + dy * dy;\n if (d2 > 4 * delta2 && depth--) {\n var a = a0 + a1,\n b = b0 + b1,\n c = c0 + c1,\n m = sqrt(a * a + b * b + c * c),\n phi2 = asin(c /= m),\n lambda2 = abs(abs(c) - 1) < epsilon || abs(lambda0 - lambda1) < epsilon ? (lambda0 + lambda1) / 2 : atan2(b, a),\n p = project(lambda2, phi2),\n x2 = p[0],\n y2 = p[1],\n dx2 = x2 - x0,\n dy2 = y2 - y0,\n dz = dy * dx2 - dx * dy2;\n if (dz * dz / d2 > delta2 // perpendicular projected distance\n || abs((dx * dx2 + dy * dy2) / d2 - 0.5) > 0.3 // midpoint close to an end\n || a0 * a1 + b0 * b1 + c0 * c1 < cosMinDistance) { // angular distance\n resampleLineTo(x0, y0, lambda0, a0, b0, c0, x2, y2, lambda2, a /= m, b /= m, c, depth, stream);\n stream.point(x2, y2);\n resampleLineTo(x2, y2, lambda2, a, b, c, x1, y1, lambda1, a1, b1, c1, depth, stream);\n }\n }\n }\n return function(stream) {\n var lambda00, x00, y00, a00, b00, c00, // first point\n lambda0, x0, y0, a0, b0, c0; // previous point\n\n var resampleStream = {\n point: point,\n lineStart: lineStart,\n lineEnd: lineEnd,\n polygonStart: function() { stream.polygonStart(); resampleStream.lineStart = ringStart; },\n polygonEnd: function() { stream.polygonEnd(); resampleStream.lineStart = lineStart; }\n };\n\n function point(x, y) {\n x = project(x, y);\n stream.point(x[0], x[1]);\n }\n\n function lineStart() {\n x0 = NaN;\n resampleStream.point = linePoint;\n stream.lineStart();\n }\n\n function linePoint(lambda, phi) {\n var c = cartesian([lambda, phi]), p = project(lambda, phi);\n resampleLineTo(x0, y0, lambda0, a0, b0, c0, x0 = p[0], y0 = p[1], lambda0 = lambda, a0 = c[0], b0 = c[1], c0 = c[2], maxDepth, stream);\n stream.point(x0, y0);\n }\n\n function lineEnd() {\n resampleStream.point = point;\n stream.lineEnd();\n }\n\n function ringStart() {\n lineStart();\n resampleStream.point = ringPoint;\n resampleStream.lineEnd = ringEnd;\n }\n\n function ringPoint(lambda, phi) {\n linePoint(lambda00 = lambda, phi), x00 = x0, y00 = y0, a00 = a0, b00 = b0, c00 = c0;\n resampleStream.point = linePoint;\n }\n\n function ringEnd() {\n resampleLineTo(x0, y0, lambda0, a0, b0, c0, x00, y00, lambda00, a00, b00, c00, maxDepth, stream);\n resampleStream.lineEnd = lineEnd;\n lineEnd();\n }\n\n return resampleStream;\n };\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/resample.js","import clipAntimeridian from \"../clip/antimeridian.js\";\nimport clipCircle from \"../clip/circle.js\";\nimport clipRectangle from \"../clip/rectangle.js\";\nimport compose from \"../compose.js\";\nimport identity from \"../identity.js\";\nimport {cos, degrees, radians, sin, sqrt} from \"../math.js\";\nimport {rotateRadians} from \"../rotation.js\";\nimport {transformer} from \"../transform.js\";\nimport {fitExtent, fitSize, fitWidth, fitHeight} from \"./fit.js\";\nimport resample from \"./resample.js\";\n\nvar transformRadians = transformer({\n point: function(x, y) {\n this.stream.point(x * radians, y * radians);\n }\n});\n\nfunction transformRotate(rotate) {\n return transformer({\n point: function(x, y) {\n var r = rotate(x, y);\n return this.stream.point(r[0], r[1]);\n }\n });\n}\n\nfunction scaleTranslate(k, dx, dy, sx, sy) {\n function transform(x, y) {\n x *= sx; y *= sy;\n return [dx + k * x, dy - k * y];\n }\n transform.invert = function(x, y) {\n return [(x - dx) / k * sx, (dy - y) / k * sy];\n };\n return transform;\n}\n\nfunction scaleTranslateRotate(k, dx, dy, sx, sy, alpha) {\n if (!alpha) return scaleTranslate(k, dx, dy, sx, sy);\n var cosAlpha = cos(alpha),\n sinAlpha = sin(alpha),\n a = cosAlpha * k,\n b = sinAlpha * k,\n ai = cosAlpha / k,\n bi = sinAlpha / k,\n ci = (sinAlpha * dy - cosAlpha * dx) / k,\n fi = (sinAlpha * dx + cosAlpha * dy) / k;\n function transform(x, y) {\n x *= sx; y *= sy;\n return [a * x - b * y + dx, dy - b * x - a * y];\n }\n transform.invert = function(x, y) {\n return [sx * (ai * x - bi * y + ci), sy * (fi - bi * x - ai * y)];\n };\n return transform;\n}\n\nexport default function projection(project) {\n return projectionMutator(function() { return project; })();\n}\n\nexport function projectionMutator(projectAt) {\n var project,\n k = 150, // scale\n x = 480, y = 250, // translate\n lambda = 0, phi = 0, // center\n deltaLambda = 0, deltaPhi = 0, deltaGamma = 0, rotate, // pre-rotate\n alpha = 0, // post-rotate angle\n sx = 1, // reflectX\n sy = 1, // reflectX\n theta = null, preclip = clipAntimeridian, // pre-clip angle\n x0 = null, y0, x1, y1, postclip = identity, // post-clip extent\n delta2 = 0.5, // precision\n projectResample,\n projectTransform,\n projectRotateTransform,\n cache,\n cacheStream;\n\n function projection(point) {\n return projectRotateTransform(point[0] * radians, point[1] * radians);\n }\n\n function invert(point) {\n point = projectRotateTransform.invert(point[0], point[1]);\n return point && [point[0] * degrees, point[1] * degrees];\n }\n\n projection.stream = function(stream) {\n return cache && cacheStream === stream ? cache : cache = transformRadians(transformRotate(rotate)(preclip(projectResample(postclip(cacheStream = stream)))));\n };\n\n projection.preclip = function(_) {\n return arguments.length ? (preclip = _, theta = undefined, reset()) : preclip;\n };\n\n projection.postclip = function(_) {\n return arguments.length ? (postclip = _, x0 = y0 = x1 = y1 = null, reset()) : postclip;\n };\n\n projection.clipAngle = function(_) {\n return arguments.length ? (preclip = +_ ? clipCircle(theta = _ * radians) : (theta = null, clipAntimeridian), reset()) : theta * degrees;\n };\n\n projection.clipExtent = function(_) {\n return arguments.length ? (postclip = _ == null ? (x0 = y0 = x1 = y1 = null, identity) : clipRectangle(x0 = +_[0][0], y0 = +_[0][1], x1 = +_[1][0], y1 = +_[1][1]), reset()) : x0 == null ? null : [[x0, y0], [x1, y1]];\n };\n\n projection.scale = function(_) {\n return arguments.length ? (k = +_, recenter()) : k;\n };\n\n projection.translate = function(_) {\n return arguments.length ? (x = +_[0], y = +_[1], recenter()) : [x, y];\n };\n\n projection.center = function(_) {\n return arguments.length ? (lambda = _[0] % 360 * radians, phi = _[1] % 360 * radians, recenter()) : [lambda * degrees, phi * degrees];\n };\n\n projection.rotate = function(_) {\n return arguments.length ? (deltaLambda = _[0] % 360 * radians, deltaPhi = _[1] % 360 * radians, deltaGamma = _.length > 2 ? _[2] % 360 * radians : 0, recenter()) : [deltaLambda * degrees, deltaPhi * degrees, deltaGamma * degrees];\n };\n\n projection.angle = function(_) {\n return arguments.length ? (alpha = _ % 360 * radians, recenter()) : alpha * degrees;\n };\n\n projection.reflectX = function(_) {\n return arguments.length ? (sx = _ ? -1 : 1, recenter()) : sx < 0;\n };\n\n projection.reflectY = function(_) {\n return arguments.length ? (sy = _ ? -1 : 1, recenter()) : sy < 0;\n };\n\n projection.precision = function(_) {\n return arguments.length ? (projectResample = resample(projectTransform, delta2 = _ * _), reset()) : sqrt(delta2);\n };\n\n projection.fitExtent = function(extent, object) {\n return fitExtent(projection, extent, object);\n };\n\n projection.fitSize = function(size, object) {\n return fitSize(projection, size, object);\n };\n\n projection.fitWidth = function(width, object) {\n return fitWidth(projection, width, object);\n };\n\n projection.fitHeight = function(height, object) {\n return fitHeight(projection, height, object);\n };\n\n function recenter() {\n var center = scaleTranslateRotate(k, 0, 0, sx, sy, alpha).apply(null, project(lambda, phi)),\n transform = scaleTranslateRotate(k, x - center[0], y - center[1], sx, sy, alpha);\n rotate = rotateRadians(deltaLambda, deltaPhi, deltaGamma);\n projectTransform = compose(project, transform);\n projectRotateTransform = compose(rotate, projectTransform);\n projectResample = resample(projectTransform, delta2);\n return reset();\n }\n\n function reset() {\n cache = cacheStream = null;\n return projection;\n }\n\n return function() {\n project = projectAt.apply(this, arguments);\n projection.invert = project.invert && invert;\n return recenter();\n };\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/index.js","import {degrees, pi, radians} from \"../math.js\";\nimport {projectionMutator} from \"./index.js\";\n\nexport function conicProjection(projectAt) {\n var phi0 = 0,\n phi1 = pi / 3,\n m = projectionMutator(projectAt),\n p = m(phi0, phi1);\n\n p.parallels = function(_) {\n return arguments.length ? m(phi0 = _[0] * radians, phi1 = _[1] * radians) : [phi0 * degrees, phi1 * degrees];\n };\n\n return p;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conic.js","import {abs, asin, atan2, cos, epsilon, pi, sign, sin, sqrt} from \"../math.js\";\nimport {conicProjection} from \"./conic.js\";\nimport {cylindricalEqualAreaRaw} from \"./cylindricalEqualArea.js\";\n\nexport function conicEqualAreaRaw(y0, y1) {\n var sy0 = sin(y0), n = (sy0 + sin(y1)) / 2;\n\n // Are the parallels symmetrical around the Equator?\n if (abs(n) < epsilon) return cylindricalEqualAreaRaw(y0);\n\n var c = 1 + sy0 * (2 * n - sy0), r0 = sqrt(c) / n;\n\n function project(x, y) {\n var r = sqrt(c - 2 * n * sin(y)) / n;\n return [r * sin(x *= n), r0 - r * cos(x)];\n }\n\n project.invert = function(x, y) {\n var r0y = r0 - y,\n l = atan2(x, abs(r0y)) * sign(r0y);\n if (r0y * n < 0)\n l -= pi * sign(x) * sign(r0y);\n return [l / n, asin((c - (x * x + r0y * r0y) * n * n) / (2 * n))];\n };\n\n return project;\n}\n\nexport default function() {\n return conicProjection(conicEqualAreaRaw)\n .scale(155.424)\n .center([0, 33.6442]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conicEqualArea.js","import {asin, cos, sin} from \"../math.js\";\n\nexport function cylindricalEqualAreaRaw(phi0) {\n var cosPhi0 = cos(phi0);\n\n function forward(lambda, phi) {\n return [lambda * cosPhi0, sin(phi) / cosPhi0];\n }\n\n forward.invert = function(x, y) {\n return [x / cosPhi0, asin(y * cosPhi0)];\n };\n\n return forward;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/cylindricalEqualArea.js","import conicEqualArea from \"./conicEqualArea.js\";\n\nexport default function() {\n return conicEqualArea()\n .parallels([29.5, 45.5])\n .scale(1070)\n .translate([480, 250])\n .rotate([96, 0])\n .center([-0.6, 38.7]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/albers.js","import {epsilon} from \"../math.js\";\nimport albers from \"./albers.js\";\nimport conicEqualArea from \"./conicEqualArea.js\";\nimport {fitExtent, fitSize, fitWidth, fitHeight} from \"./fit.js\";\n\n// The projections must have mutually exclusive clip regions on the sphere,\n// as this will avoid emitting interleaving lines and polygons.\nfunction multiplex(streams) {\n var n = streams.length;\n return {\n point: function(x, y) { var i = -1; while (++i < n) streams[i].point(x, y); },\n sphere: function() { var i = -1; while (++i < n) streams[i].sphere(); },\n lineStart: function() { var i = -1; while (++i < n) streams[i].lineStart(); },\n lineEnd: function() { var i = -1; while (++i < n) streams[i].lineEnd(); },\n polygonStart: function() { var i = -1; while (++i < n) streams[i].polygonStart(); },\n polygonEnd: function() { var i = -1; while (++i < n) streams[i].polygonEnd(); }\n };\n}\n\n// A composite projection for the United States, configured by default for\n// 960×500. The projection also works quite well at 960×600 if you change the\n// scale to 1285 and adjust the translate accordingly. The set of standard\n// parallels for each region comes from USGS, which is published here:\n// http://egsc.usgs.gov/isb/pubs/MapProjections/projections.html#albers\nexport default function() {\n var cache,\n cacheStream,\n lower48 = albers(), lower48Point,\n alaska = conicEqualArea().rotate([154, 0]).center([-2, 58.5]).parallels([55, 65]), alaskaPoint, // EPSG:3338\n hawaii = conicEqualArea().rotate([157, 0]).center([-3, 19.9]).parallels([8, 18]), hawaiiPoint, // ESRI:102007\n point, pointStream = {point: function(x, y) { point = [x, y]; }};\n\n function albersUsa(coordinates) {\n var x = coordinates[0], y = coordinates[1];\n return point = null,\n (lower48Point.point(x, y), point)\n || (alaskaPoint.point(x, y), point)\n || (hawaiiPoint.point(x, y), point);\n }\n\n albersUsa.invert = function(coordinates) {\n var k = lower48.scale(),\n t = lower48.translate(),\n x = (coordinates[0] - t[0]) / k,\n y = (coordinates[1] - t[1]) / k;\n return (y >= 0.120 && y < 0.234 && x >= -0.425 && x < -0.214 ? alaska\n : y >= 0.166 && y < 0.234 && x >= -0.214 && x < -0.115 ? hawaii\n : lower48).invert(coordinates);\n };\n\n albersUsa.stream = function(stream) {\n return cache && cacheStream === stream ? cache : cache = multiplex([lower48.stream(cacheStream = stream), alaska.stream(stream), hawaii.stream(stream)]);\n };\n\n albersUsa.precision = function(_) {\n if (!arguments.length) return lower48.precision();\n lower48.precision(_), alaska.precision(_), hawaii.precision(_);\n return reset();\n };\n\n albersUsa.scale = function(_) {\n if (!arguments.length) return lower48.scale();\n lower48.scale(_), alaska.scale(_ * 0.35), hawaii.scale(_);\n return albersUsa.translate(lower48.translate());\n };\n\n albersUsa.translate = function(_) {\n if (!arguments.length) return lower48.translate();\n var k = lower48.scale(), x = +_[0], y = +_[1];\n\n lower48Point = lower48\n .translate(_)\n .clipExtent([[x - 0.455 * k, y - 0.238 * k], [x + 0.455 * k, y + 0.238 * k]])\n .stream(pointStream);\n\n alaskaPoint = alaska\n .translate([x - 0.307 * k, y + 0.201 * k])\n .clipExtent([[x - 0.425 * k + epsilon, y + 0.120 * k + epsilon], [x - 0.214 * k - epsilon, y + 0.234 * k - epsilon]])\n .stream(pointStream);\n\n hawaiiPoint = hawaii\n .translate([x - 0.205 * k, y + 0.212 * k])\n .clipExtent([[x - 0.214 * k + epsilon, y + 0.166 * k + epsilon], [x - 0.115 * k - epsilon, y + 0.234 * k - epsilon]])\n .stream(pointStream);\n\n return reset();\n };\n\n albersUsa.fitExtent = function(extent, object) {\n return fitExtent(albersUsa, extent, object);\n };\n\n albersUsa.fitSize = function(size, object) {\n return fitSize(albersUsa, size, object);\n };\n\n albersUsa.fitWidth = function(width, object) {\n return fitWidth(albersUsa, width, object);\n };\n\n albersUsa.fitHeight = function(height, object) {\n return fitHeight(albersUsa, height, object);\n };\n\n function reset() {\n cache = cacheStream = null;\n return albersUsa;\n }\n\n return albersUsa.scale(1070);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/albersUsa.js","import {asin, atan2, cos, sin, sqrt} from \"../math.js\";\n\nexport function azimuthalRaw(scale) {\n return function(x, y) {\n var cx = cos(x),\n cy = cos(y),\n k = scale(cx * cy);\n if (k === Infinity) return [2, 0];\n return [\n k * cy * sin(x),\n k * sin(y)\n ];\n }\n}\n\nexport function azimuthalInvert(angle) {\n return function(x, y) {\n var z = sqrt(x * x + y * y),\n c = angle(z),\n sc = sin(c),\n cc = cos(c);\n return [\n atan2(x * sc, z * cc),\n asin(z && y * sc / z)\n ];\n }\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/azimuthal.js","import {asin, sqrt} from \"../math.js\";\nimport {azimuthalRaw, azimuthalInvert} from \"./azimuthal.js\";\nimport projection from \"./index.js\";\n\nexport var azimuthalEqualAreaRaw = azimuthalRaw(function(cxcy) {\n return sqrt(2 / (1 + cxcy));\n});\n\nazimuthalEqualAreaRaw.invert = azimuthalInvert(function(z) {\n return 2 * asin(z / 2);\n});\n\nexport default function() {\n return projection(azimuthalEqualAreaRaw)\n .scale(124.75)\n .clipAngle(180 - 1e-3);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/azimuthalEqualArea.js","import {acos, sin} from \"../math.js\";\nimport {azimuthalRaw, azimuthalInvert} from \"./azimuthal.js\";\nimport projection from \"./index.js\";\n\nexport var azimuthalEquidistantRaw = azimuthalRaw(function(c) {\n return (c = acos(c)) && c / sin(c);\n});\n\nazimuthalEquidistantRaw.invert = azimuthalInvert(function(z) {\n return z;\n});\n\nexport default function() {\n return projection(azimuthalEquidistantRaw)\n .scale(79.4188)\n .clipAngle(180 - 1e-3);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/azimuthalEquidistant.js","import {atan, exp, halfPi, log, pi, tan, tau} from \"../math.js\";\nimport rotation from \"../rotation.js\";\nimport projection from \"./index.js\";\n\nexport function mercatorRaw(lambda, phi) {\n return [lambda, log(tan((halfPi + phi) / 2))];\n}\n\nmercatorRaw.invert = function(x, y) {\n return [x, 2 * atan(exp(y)) - halfPi];\n};\n\nexport default function() {\n return mercatorProjection(mercatorRaw)\n .scale(961 / tau);\n}\n\nexport function mercatorProjection(project) {\n var m = projection(project),\n center = m.center,\n scale = m.scale,\n translate = m.translate,\n clipExtent = m.clipExtent,\n x0 = null, y0, x1, y1; // clip extent\n\n m.scale = function(_) {\n return arguments.length ? (scale(_), reclip()) : scale();\n };\n\n m.translate = function(_) {\n return arguments.length ? (translate(_), reclip()) : translate();\n };\n\n m.center = function(_) {\n return arguments.length ? (center(_), reclip()) : center();\n };\n\n m.clipExtent = function(_) {\n return arguments.length ? ((_ == null ? x0 = y0 = x1 = y1 = null : (x0 = +_[0][0], y0 = +_[0][1], x1 = +_[1][0], y1 = +_[1][1])), reclip()) : x0 == null ? null : [[x0, y0], [x1, y1]];\n };\n\n function reclip() {\n var k = pi * scale(),\n t = m(rotation(m.rotate()).invert([0, 0]));\n return clipExtent(x0 == null\n ? [[t[0] - k, t[1] - k], [t[0] + k, t[1] + k]] : project === mercatorRaw\n ? [[Math.max(t[0] - k, x0), y0], [Math.min(t[0] + k, x1), y1]]\n : [[x0, Math.max(t[1] - k, y0)], [x1, Math.min(t[1] + k, y1)]]);\n }\n\n return reclip();\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/mercator.js","import {abs, atan, atan2, cos, epsilon, halfPi, log, pi, pow, sign, sin, sqrt, tan} from \"../math.js\";\nimport {conicProjection} from \"./conic.js\";\nimport {mercatorRaw} from \"./mercator.js\";\n\nfunction tany(y) {\n return tan((halfPi + y) / 2);\n}\n\nexport function conicConformalRaw(y0, y1) {\n var cy0 = cos(y0),\n n = y0 === y1 ? sin(y0) : log(cy0 / cos(y1)) / log(tany(y1) / tany(y0)),\n f = cy0 * pow(tany(y0), n) / n;\n\n if (!n) return mercatorRaw;\n\n function project(x, y) {\n if (f > 0) { if (y < -halfPi + epsilon) y = -halfPi + epsilon; }\n else { if (y > halfPi - epsilon) y = halfPi - epsilon; }\n var r = f / pow(tany(y), n);\n return [r * sin(n * x), f - r * cos(n * x)];\n }\n\n project.invert = function(x, y) {\n var fy = f - y, r = sign(n) * sqrt(x * x + fy * fy),\n l = atan2(x, abs(fy)) * sign(fy);\n if (fy * n < 0)\n l -= pi * sign(x) * sign(fy);\n return [l / n, 2 * atan(pow(f / r, 1 / n)) - halfPi];\n };\n\n return project;\n}\n\nexport default function() {\n return conicProjection(conicConformalRaw)\n .scale(109.5)\n .parallels([30, 30]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conicConformal.js","import projection from \"./index.js\";\n\nexport function equirectangularRaw(lambda, phi) {\n return [lambda, phi];\n}\n\nequirectangularRaw.invert = equirectangularRaw;\n\nexport default function() {\n return projection(equirectangularRaw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/equirectangular.js","import {abs, atan2, cos, epsilon, pi, sign, sin, sqrt} from \"../math.js\";\nimport {conicProjection} from \"./conic.js\";\nimport {equirectangularRaw} from \"./equirectangular.js\";\n\nexport function conicEquidistantRaw(y0, y1) {\n var cy0 = cos(y0),\n n = y0 === y1 ? sin(y0) : (cy0 - cos(y1)) / (y1 - y0),\n g = cy0 / n + y0;\n\n if (abs(n) < epsilon) return equirectangularRaw;\n\n function project(x, y) {\n var gy = g - y, nx = n * x;\n return [gy * sin(nx), g - gy * cos(nx)];\n }\n\n project.invert = function(x, y) {\n var gy = g - y,\n l = atan2(x, abs(gy)) * sign(gy);\n if (gy * n < 0)\n l -= pi * sign(x) * sign(gy);\n return [l / n, g - sign(n) * sqrt(x * x + gy * gy)];\n };\n\n return project;\n}\n\nexport default function() {\n return conicProjection(conicEquidistantRaw)\n .scale(131.154)\n .center([0, 13.9389]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/conicEquidistant.js","import projection from \"./index.js\";\nimport {abs, asin, cos, epsilon2, sin, sqrt} from \"../math.js\";\n\nvar A1 = 1.340264,\n A2 = -0.081106,\n A3 = 0.000893,\n A4 = 0.003796,\n M = sqrt(3) / 2,\n iterations = 12;\n\nexport function equalEarthRaw(lambda, phi) {\n var l = asin(M * sin(phi)), l2 = l * l, l6 = l2 * l2 * l2;\n return [\n lambda * cos(l) / (M * (A1 + 3 * A2 * l2 + l6 * (7 * A3 + 9 * A4 * l2))),\n l * (A1 + A2 * l2 + l6 * (A3 + A4 * l2))\n ];\n}\n\nequalEarthRaw.invert = function(x, y) {\n var l = y, l2 = l * l, l6 = l2 * l2 * l2;\n for (var i = 0, delta, fy, fpy; i < iterations; ++i) {\n fy = l * (A1 + A2 * l2 + l6 * (A3 + A4 * l2)) - y;\n fpy = A1 + 3 * A2 * l2 + l6 * (7 * A3 + 9 * A4 * l2);\n l -= delta = fy / fpy, l2 = l * l, l6 = l2 * l2 * l2;\n if (abs(delta) < epsilon2) break;\n }\n return [\n M * x * (A1 + 3 * A2 * l2 + l6 * (7 * A3 + 9 * A4 * l2)) / cos(l),\n asin(sin(l) / M)\n ];\n};\n\nexport default function() {\n return projection(equalEarthRaw)\n .scale(177.158);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/equalEarth.js","import {atan, cos, sin} from \"../math.js\";\nimport {azimuthalInvert} from \"./azimuthal.js\";\nimport projection from \"./index.js\";\n\nexport function gnomonicRaw(x, y) {\n var cy = cos(y), k = cos(x) * cy;\n return [cy * sin(x) / k, sin(y) / k];\n}\n\ngnomonicRaw.invert = azimuthalInvert(atan);\n\nexport default function() {\n return projection(gnomonicRaw)\n .scale(144.049)\n .clipAngle(60);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/gnomonic.js","import clipRectangle from \"../clip/rectangle.js\";\nimport identity from \"../identity.js\";\nimport {transformer} from \"../transform.js\";\nimport {fitExtent, fitSize, fitWidth, fitHeight} from \"./fit.js\";\nimport {cos, degrees, radians, sin} from \"../math.js\";\n\nexport default function() {\n var k = 1, tx = 0, ty = 0, sx = 1, sy = 1, // scale, translate and reflect\n alpha = 0, ca, sa, // angle\n x0 = null, y0, x1, y1, // clip extent\n kx = 1, ky = 1,\n transform = transformer({\n point: function(x, y) {\n var p = projection([x, y])\n this.stream.point(p[0], p[1]);\n }\n }),\n postclip = identity,\n cache,\n cacheStream;\n\n function reset() {\n kx = k * sx;\n ky = k * sy;\n cache = cacheStream = null;\n return projection;\n }\n\n function projection (p) {\n var x = p[0] * kx, y = p[1] * ky;\n if (alpha) {\n var t = y * ca - x * sa;\n x = x * ca + y * sa;\n y = t;\n } \n return [x + tx, y + ty];\n }\n projection.invert = function(p) {\n var x = p[0] - tx, y = p[1] - ty;\n if (alpha) {\n var t = y * ca + x * sa;\n x = x * ca - y * sa;\n y = t;\n }\n return [x / kx, y / ky];\n };\n projection.stream = function(stream) {\n return cache && cacheStream === stream ? cache : cache = transform(postclip(cacheStream = stream));\n };\n projection.postclip = function(_) {\n return arguments.length ? (postclip = _, x0 = y0 = x1 = y1 = null, reset()) : postclip;\n };\n projection.clipExtent = function(_) {\n return arguments.length ? (postclip = _ == null ? (x0 = y0 = x1 = y1 = null, identity) : clipRectangle(x0 = +_[0][0], y0 = +_[0][1], x1 = +_[1][0], y1 = +_[1][1]), reset()) : x0 == null ? null : [[x0, y0], [x1, y1]];\n };\n projection.scale = function(_) {\n return arguments.length ? (k = +_, reset()) : k;\n };\n projection.translate = function(_) {\n return arguments.length ? (tx = +_[0], ty = +_[1], reset()) : [tx, ty];\n }\n projection.angle = function(_) {\n return arguments.length ? (alpha = _ % 360 * radians, sa = sin(alpha), ca = cos(alpha), reset()) : alpha * degrees;\n };\n projection.reflectX = function(_) {\n return arguments.length ? (sx = _ ? -1 : 1, reset()) : sx < 0;\n };\n projection.reflectY = function(_) {\n return arguments.length ? (sy = _ ? -1 : 1, reset()) : sy < 0;\n };\n projection.fitExtent = function(extent, object) {\n return fitExtent(projection, extent, object);\n };\n projection.fitSize = function(size, object) {\n return fitSize(projection, size, object);\n };\n projection.fitWidth = function(width, object) {\n return fitWidth(projection, width, object);\n };\n projection.fitHeight = function(height, object) {\n return fitHeight(projection, height, object);\n };\n\n return projection;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/identity.js","import projection from \"./index.js\";\nimport {abs, epsilon} from \"../math.js\";\n\nexport function naturalEarth1Raw(lambda, phi) {\n var phi2 = phi * phi, phi4 = phi2 * phi2;\n return [\n lambda * (0.8707 - 0.131979 * phi2 + phi4 * (-0.013791 + phi4 * (0.003971 * phi2 - 0.001529 * phi4))),\n phi * (1.007226 + phi2 * (0.015085 + phi4 * (-0.044475 + 0.028874 * phi2 - 0.005916 * phi4)))\n ];\n}\n\nnaturalEarth1Raw.invert = function(x, y) {\n var phi = y, i = 25, delta;\n do {\n var phi2 = phi * phi, phi4 = phi2 * phi2;\n phi -= delta = (phi * (1.007226 + phi2 * (0.015085 + phi4 * (-0.044475 + 0.028874 * phi2 - 0.005916 * phi4))) - y) /\n (1.007226 + phi2 * (0.015085 * 3 + phi4 * (-0.044475 * 7 + 0.028874 * 9 * phi2 - 0.005916 * 11 * phi4)));\n } while (abs(delta) > epsilon && --i > 0);\n return [\n x / (0.8707 + (phi2 = phi * phi) * (-0.131979 + phi2 * (-0.013791 + phi2 * phi2 * phi2 * (0.003971 - 0.001529 * phi2)))),\n phi\n ];\n};\n\nexport default function() {\n return projection(naturalEarth1Raw)\n .scale(175.295);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/naturalEarth1.js","import {asin, cos, epsilon, sin} from \"../math.js\";\nimport {azimuthalInvert} from \"./azimuthal.js\";\nimport projection from \"./index.js\";\n\nexport function orthographicRaw(x, y) {\n return [cos(y) * sin(x), sin(y)];\n}\n\northographicRaw.invert = azimuthalInvert(asin);\n\nexport default function() {\n return projection(orthographicRaw)\n .scale(249.5)\n .clipAngle(90 + epsilon);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/orthographic.js","import {atan, cos, sin} from \"../math.js\";\nimport {azimuthalInvert} from \"./azimuthal.js\";\nimport projection from \"./index.js\";\n\nexport function stereographicRaw(x, y) {\n var cy = cos(y), k = 1 + cos(x) * cy;\n return [cy * sin(x) / k, sin(y) / k];\n}\n\nstereographicRaw.invert = azimuthalInvert(function(z) {\n return 2 * atan(z);\n});\n\nexport default function() {\n return projection(stereographicRaw)\n .scale(250)\n .clipAngle(142);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/stereographic.js","import {atan, exp, halfPi, log, tan} from \"../math.js\";\nimport {mercatorProjection} from \"./mercator.js\";\n\nexport function transverseMercatorRaw(lambda, phi) {\n return [log(tan((halfPi + phi) / 2)), -lambda];\n}\n\ntransverseMercatorRaw.invert = function(x, y) {\n return [-y, 2 * atan(exp(x)) - halfPi];\n};\n\nexport default function() {\n var m = mercatorProjection(transverseMercatorRaw),\n center = m.center,\n rotate = m.rotate;\n\n m.center = function(_) {\n return arguments.length ? center([-_[1], _[0]]) : (_ = center(), [_[1], -_[0]]);\n };\n\n m.rotate = function(_) {\n return arguments.length ? rotate([_[0], _[1], _.length > 2 ? _[2] + 90 : 90]) : (_ = rotate(), [_[0], _[1], _[2] - 90]);\n };\n\n return rotate([0, 0, 90])\n .scale(159.155);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo/src/projection/transverseMercator.js","/**\r\n * Map series module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Series, SeriesDataItem, ISeriesProperties, ISeriesDataFields, ISeriesAdapters, ISeriesEvents } from \"../series/Series\";\r\nimport { MapChart } from \"../types/MapChart\";\r\nimport { MapObject } from \"./MapObject\";\r\nimport { IListEvents } from \"../../core/utils/List\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { DataSource } from \"../../core/data/DataSource\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport * as $type from \"../../core/utils/Type\";\r\nimport * as $math from \"../../core/utils/Math\";\r\nimport { ListTemplate } from \"../../core/utils/List\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[MapSeries]].\r\n *\r\n * @see {@link DataItem}\r\n */\r\nexport class MapSeriesDataItem extends SeriesDataItem {\r\n\r\n\t/**\r\n\t * South-most latitude.\r\n\t */\r\n\tprotected _south: number;\r\n\r\n\t/**\r\n\t * North-most latitude.\r\n\t */\r\n\tprotected _north: number;\r\n\r\n\t/**\r\n\t * East-most longitude.\r\n\t */\r\n\tprotected _east: number;\r\n\r\n\t/**\r\n\t * West-most longitude.\r\n\t */\r\n\tprotected _west: number;\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for.\r\n\t */\r\n\tpublic _component!: MapSeries;\r\n\r\n\t/**\r\n\t * Shortcut to either [[MapLine]], [[MapImage]], or [[MapPolygon]].\r\n\t */\r\n\tpublic mapObject: MapObject;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapSeriesDataItem\";\r\n\t\tthis.values.value = {};\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * Numeric value of the data item.\r\n\t *\r\n\t * Value may be used in heat-map calculations.\r\n\t *\r\n\t * @param value Value\r\n\t */\r\n\tpublic set value(value: number) {\r\n\t\tthis.setValue(\"value\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Value\r\n\t */\r\n\tpublic get value(): number {\r\n\t\treturn this.values.value.value;\r\n\t}\r\n\r\n\t/**\r\n\t * When `zoomToMapObject()` is called the map will either calculate suitable\r\n\t * zoom level itself or use object's `zoomLevel` if set.\r\n\t *\r\n\t * @param value Zoom level\r\n\t */\r\n\tpublic set zoomLevel(value: number) {\r\n\t\tthis.setProperty(\"zoomLevel\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Zoom level\r\n\t */\r\n\tpublic get zoomLevel(): number {\r\n\t\treturn this.properties[\"zoomLevel\"];\r\n\t}\r\n\r\n\t/**\r\n\t * When `zoomToMapObject()` is called the map will either calculate suitable\r\n\t * center position itself or use object's `zoomGeoPoint` if set.\r\n\t *\r\n\t * @param value Zoom geo point\r\n\t */\r\n\tpublic set zoomGeoPoint(value: IGeoPoint) {\r\n\t\tthis.setProperty(\"zoomGeoPoint\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Zoom geo point\r\n\t */\r\n\tpublic get zoomGeoPoint(): IGeoPoint {\r\n\t\treturn this.properties[\"zoomGeoPoint\"];\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Longitude of the East-most point of the element.\r\n\t */\r\n\tpublic get east(): number {\r\n\t\treturn this._east;\r\n\t}\r\n\r\n\t/**\r\n\t * Longitude of the West-most point of the element.\r\n\t */\r\n\tpublic get west(): number {\r\n\t\treturn this._west;\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude of the South-most point of the element.\r\n\t */\r\n\tpublic get south(): number {\r\n\t\treturn this._south;\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude of the North-most point of the element.\r\n\t */\r\n\tpublic get north(): number {\r\n\t\treturn this._north;\r\n\t}\r\n\r\n\t/**\r\n\t * Updates the item's bounding coordinates: coordinates of the East, West,\r\n\t * North, and South-most points.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic updateExtremes(): void {\r\n\t\tlet geometry = this.getFeature().geometry;\r\n\t\tif (geometry) {\r\n\r\n\t\t\tlet bounds = d3geo.geoBounds(geometry);\r\n\r\n\t\t\tlet west = bounds[0][0];\r\n\t\t\tlet south = bounds[0][1];\r\n\r\n\t\t\tlet north = bounds[1][1];\r\n\t\t\tlet east = bounds[1][0];\r\n\r\n\t\t\tlet changed = false;\r\n\t\t\tif (north != this.north) {\r\n\t\t\t\tthis._north = $math.round(north, 6);\r\n\t\t\t\tchanged = true;\r\n\t\t\t}\r\n\r\n\t\t\tif (south != this.south) {\r\n\t\t\t\tthis._south = $math.round(south, 6);\r\n\t\t\t\tchanged = true;\r\n\t\t\t}\r\n\r\n\t\t\tif (east != this.east) {\r\n\t\t\t\tthis._east = $math.round(east, 6);\r\n\t\t\t\tchanged = true;\r\n\t\t\t}\r\n\r\n\t\t\tif (west != this.west) {\r\n\t\t\t\tthis._west = $math.round(west, 6);\r\n\t\t\t\tchanged = true;\r\n\t\t\t}\r\n\r\n\t\t\t// solves single russia prob\r\n\t\t\tif (this._east < this._west) {\r\n\t\t\t\tthis._east = 180;\r\n\t\t\t\tthis._west = -180;\r\n\t\t\t}\r\n\r\n\t\t\tif (changed) {\r\n\t\t\t\tthis.component.invalidateDataItems();\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\tpublic getFeature(): any {\r\n\t\treturn {};\r\n\t}\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * [GEOJSONGeometry description]\r\n *\r\n * @todo Description\r\n */\r\nexport type GEOJSONGeometry = \"Point\" | \"LineString\" | \"Polygon\" | \"MultiPoint\" | \"MultiLineString\" | \"MultiPolygon\";\r\n\r\n/**\r\n * Defines data fields for [[MapSeries]].\r\n *\r\n * @todo Alllow any number of values?\r\n */\r\nexport interface IMapSeriesDataFields extends ISeriesDataFields {\r\n\r\n\t/**\r\n\t * A field name in data for a numeric value of the map object.\r\n\t */\r\n\tvalue?: string;\r\n\r\n\t/**\r\n\t * A field name in data for a `zoomLevel` of the map object.\r\n\t */\r\n\tzoomLevel?: string;\r\n\r\n\t/**\r\n\t * A field name in data for a `zoomGeoPoint` of the map object.\r\n\t */\r\n\tzoomGeoPoint?: string;\r\n\r\n}\r\n\r\n/**\r\n * Defines properties for [[MapSeries]].\r\n */\r\nexport interface IMapSeriesProperties extends ISeriesProperties {\r\n\r\n\t/**\r\n\t * A flag telling if the series should get data from `geodata` or not\r\n\t *\r\n\t * @default false\r\n\t */\r\n\tuseGeodata?: boolean;\r\n\r\n\t/**\r\n\t * A list of object ids to include from the series.\r\n\t */\r\n\tinclude?: string[];\r\n\r\n\t/**\r\n\t * A list of object ids to exclude from the series.\r\n\t */\r\n\texclude?: string[];\r\n\r\n\t/**\r\n\t * Should this series be included when calculating bounds of the map?\r\n\t *\r\n\t * This affects initial zoom as well as limits for zoom/pan.\r\n\t *\r\n\t * By default, `MapPolygonSeries` included (true), while `MapImageSeries` and\r\n\t * `MapLineSeries` are not (`false`).\r\n\t */\r\n\tignoreBounds?: boolean;\r\n\r\n\t/**\r\n\t * Indicates whether GeoJSON geodata supplied to the chart uses\r\n\t * ESRI (clockwise) or non-ESRI (counter-clockwise) order of the polygon\r\n\t * coordinates.\r\n\t *\r\n\t * `MapChart` supports only ESRI standard, so if your custom maps appears\r\n\t * garbled, try setting `reverseGeodata = true`.\r\n\t * \r\n\t * @default false\r\n\t * @since 4.10.11\r\n\t */\r\n\treverseGeodata?: boolean;\r\n}\r\n\r\n/**\r\n * Defines events for [[MapSeries]].\r\n */\r\nexport interface IMapSeriesEvents extends ISeriesEvents {\r\n\tgeoBoundsChanged: {};\r\n}\r\n\r\n/**\r\n * Defines adapters for [[MapSeries]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapSeriesAdapters extends ISeriesAdapters, IMapSeriesProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * A base class for series of map objects.\r\n *\r\n * @see {@link IMapSeriesEvents} for a list of available Events\r\n * @see {@link IMapSeriesAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class MapSeries extends Series {\r\n\r\n\t/**\r\n\t * Defines available data fields.\r\n\t */\r\n\tpublic _dataFields: IMapSeriesDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapSeriesProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapSeriesAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapSeriesEvents;\r\n\r\n\t/**\r\n\t * Defines the type of data item.\r\n\t */\r\n\tpublic _dataItem: MapSeriesDataItem;\r\n\r\n\t/**\r\n\t * The longitude of the East-most point in the series. (out of all elements)\r\n\t */\r\n\tprotected _east: number;\r\n\r\n\t/**\r\n\t * The longitude of the West-most point in the series. (out of all elements)\r\n\t */\r\n\tprotected _west: number;\r\n\r\n\t/**\r\n\t * The latitude of the South-most point in the series. (out of all elements)\r\n\t */\r\n\tprotected _south: number;\r\n\r\n\t/**\r\n\t * The latitude of the North-most point in the series. (out of all elements)\r\n\t */\r\n\tprotected _north: number;\r\n\r\n\tprotected _eastDefined: number;\r\n\r\n\tprotected _westDefined: number;\r\n\r\n\tprotected _southDefined: number;\r\n\r\n\tprotected _northDefined: number;\r\n\r\n\t/**\r\n\t * A chart series belongs to.\r\n\t */\r\n\tpublic _chart: MapChart;\r\n\r\n\t/**\r\n\t * Map data in GeoJSON format.\r\n\t *\r\n\t * @see {@link http://geojson.org/} GeoJSON official specification\r\n\t */\r\n\tprotected _geodata: Object;\r\n\r\n\r\n\tprotected _mapObjects: ListTemplate;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapSeries\";\r\n\r\n\t\t// Set defaults\r\n\t\tthis.isMeasured = false;\r\n\t\tthis.nonScalingStroke = true;\r\n\r\n\t\t// Set data fields\r\n\t\tthis.dataFields.value = \"value\";\r\n\r\n\t\tthis.ignoreBounds = false;\r\n\r\n\t\tif (this.tooltip) {\r\n\t\t\tthis.tooltip.showInViewport = true;\r\n\t\t}\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new/empty DataItem of the type appropriate for this object.\r\n\t *\r\n\t * @see {@link DataItem}\r\n\t * @return Data Item\r\n\t */\r\n\tprotected createDataItem(): this[\"_dataItem\"] {\r\n\t\treturn new MapSeriesDataItem();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Checks whether object should be included in series.\r\n\t *\r\n\t * @param includes A list of explicitly included ids\r\n\t * @param excludes A list of explicitly excluded ids\r\n\t * @param id Id of the object\r\n\t * @return Include?\r\n\t */\r\n\tprotected checkInclude(includes: string[], excludes: string[], id: string): boolean {\r\n\t\tif (includes) {\r\n\t\t\tif (includes.length == 0) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tif (includes.indexOf(id) == -1) {\r\n\t\t\t\t\treturn false;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif (excludes && excludes.length > 0) {\r\n\t\t\tif (excludes.indexOf(id) != -1) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}\r\n\r\n\t/**\r\n\t * Should the map extract all the data about element from the GeoJSON?\r\n\t *\r\n\t * This is especially relevant for [[MapPolygonSeries]]. If not set to `true`\r\n\t * polygon series will need to contain geographical data in itself in order\r\n\t * to be drawn.\r\n\t *\r\n\t * If this is set to `true`, series will try to extract data for its objects\r\n\t * from either chart-level `geodata` or from series' `geodata` which holds\r\n\t * map infor in GeoJSON format.\r\n\t *\r\n\t * @default false\r\n\t * @param value Use GeoJSON data?\r\n\t */\r\n\tpublic set useGeodata(value: boolean) {\r\n\t\tif (this.setPropertyValue(\"useGeodata\", value)) {\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Use GeoJSON data?\r\n\t */\r\n\tpublic get useGeodata(): boolean {\r\n\t\treturn this.getPropertyValue(\"useGeodata\");\r\n\t}\r\n\r\n\t/**\r\n\t * A list of object ids that should be explictly included in the series.\r\n\t *\r\n\t * If this is not set, the series will automatically include all of the\r\n\t * objects, available in the GeoJSON map. (minus the ones listed in\r\n\t * `exclude`)\r\n\t *\r\n\t * If you need to display only specific objects, use `include`. E.g.:\r\n\t *\r\n\t * `include = [\"FR\", \"ES\", \"DE\"];`\r\n\t *\r\n\t * The above will show only France, Spain, and Germany out of the whole map.\r\n\t *\r\n\t * @param value Included objects\r\n\t */\r\n\tpublic set include(value: string[]) {\r\n\t\tif (this.setPropertyValue(\"include\", value)) {\r\n\t\t\tthis.processIncExc();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected processIncExc() {\r\n\t\t//this.data = [];\r\n\t\tthis.invalidateData();\r\n\t}\r\n\r\n\t/**\r\n\t * @return Included objects\r\n\t */\r\n\tpublic get include(): string[] {\r\n\t\treturn this.getPropertyValue(\"include\");\r\n\t}\r\n\r\n\t/**\r\n\t * Should this series be included when calculating bounds of the map?\r\n\t *\r\n\t * This affects initial zoom as well as limits for zoom/pan.\r\n\t *\r\n\t * By default, `MapPolygonSeries` included (true), while `MapImageSeries` and\r\n\t * `MapLineSeries` are not (`false`).\r\n\t *\r\n\t * @since 4.3.0\r\n\t * @param value Ignore bounds?\r\n\t */\r\n\tpublic set ignoreBounds(value: boolean) {\r\n\t\tif (this.setPropertyValue(\"ignoreBounds\", value)) {\r\n\t\t\tif (this.chart) {\r\n\t\t\t\tthis.chart.updateExtremes();\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Ignore bounds?\r\n\t */\r\n\tpublic get ignoreBounds(): boolean {\r\n\t\treturn this.getPropertyValue(\"ignoreBounds\");\r\n\t}\r\n\r\n\t/**\r\n\t * A list of object ids that should be excluded from the series.\r\n\t *\r\n\t * E.g. you want to include all of the areas from a GeoJSON map, except\r\n\t * Antarctica.\r\n\t *\r\n\t * You'd leave `include` empty, and set `exclude = [\"AQ\"]`.\r\n\t *\r\n\t * @param value Excluded ids\r\n\t */\r\n\tpublic set exclude(value: string[]) {\r\n\t\tif (this.setPropertyValue(\"exclude\", value)) {\r\n\t\t\tthis.processIncExc();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Excluded ids\r\n\t */\r\n\tpublic get exclude(): string[] {\r\n\t\treturn this.getPropertyValue(\"exclude\");\r\n\t}\r\n\r\n\t/**\r\n\t * Decorates a newly added object.\r\n\t *\r\n\t * @param event [description]\r\n\t */\r\n\tprotected handleObjectAdded(event: IListEvents[\"inserted\"]) {\r\n\t\tlet mapObject: MapObject = event.newValue;\r\n\t\tmapObject.parent = this;\r\n\t\tmapObject.series = this;\r\n\t\tmapObject.strokeWidth = mapObject.strokeWidth;\r\n\t}\r\n\r\n\t/**\r\n\t * Map data in GeoJSON format.\r\n\t *\r\n\t * The series supports the following GeoJSON objects: `Point`, `LineString`,\r\n\t * `Polygon`, `MultiPoint`, `MultiLineString`, and `MultiPolygon`.\r\n\t *\r\n\t * @see {@link http://geojson.org/} Official GeoJSON format specification\r\n\t * @param geoJSON GeoJSON data\r\n\t */\r\n\tpublic set geodata(geodata: Object) {\r\n\t\tif (geodata != this._geodata) {\r\n\t\t\tthis._geodata = geodata;\r\n\t\t\tif (this.reverseGeodata) {\r\n\t\t\t\tthis.chart.processReverseGeodata(this._geodata);\r\n\t\t\t}\r\n\t\t\tfor (let i = this.data.length - 1; i >= 0; i--) {\r\n\t\t\t\tif (this.data[i].madeFromGeoData == true) {\r\n\t\t\t\t\tthis.data.splice(i, 1);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tthis.disposeData();\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return GeoJSON data\r\n\t */\r\n\tpublic get geodata(): Object {\r\n\t\treturn this._geodata;\r\n\t}\r\n\r\n\t/**\r\n\t * Indicates whether GeoJSON geodata supplied to the chart uses\r\n\t * ESRI (clockwise) or non-ESRI (counter-clockwise) order of the polygon\r\n\t * coordinates.\r\n\t *\r\n\t * `MapChart` supports only ESRI standard, so if your custom maps appears\r\n\t * garbled, try setting `reverseGeodata = true`.\r\n\t * \r\n\t * @default false\r\n\t * @since 4.10.11\r\n\t * @param value Reverse the order of geodata coordinates?\r\n\t */\r\n\tpublic set reverseGeodata(value: boolean) {\r\n\t\tif (this.setPropertyValue(\"reverseGeodata\", value) && this._geodata) {\r\n\t\t\tthis.chart.processReverseGeodata(this._geodata);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @returns Reverse the order of geodata coordinates?\r\n\t */\r\n\tpublic get reverseGeodata(): boolean {\r\n\t\treturn this.getPropertyValue(\"reverseGeodata\");\r\n\t}\r\n\r\n\t/**\r\n\t * Sets a [[DataSource]] to be used for loading Component's data.\r\n\t *\r\n\t * @param value Data source\r\n\t */\r\n\tpublic set geodataSource(value: DataSource) {\r\n\t\tif (this._dataSources[\"geodata\"]) {\r\n\t\t\tthis.removeDispose(this._dataSources[\"geodata\"]);\r\n\t\t}\r\n\t\tthis._dataSources[\"geodata\"] = value;\r\n\t\tthis._dataSources[\"geodata\"].component = this;\r\n\t\tthis.events.on(\"inited\", () => {\r\n\t\t\tthis.loadData(\"geodata\")\r\n\t\t}, undefined, false);\r\n\t\tthis.setDataSourceEvents(value, \"geodata\");\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Returns a [[DataSource]] specifically for loading Component's data.\r\n\t *\r\n\t * @return Data source\r\n\t */\r\n\tpublic get geodataSource(): DataSource {\r\n\t\tif (!this._dataSources[\"geodata\"]) {\r\n\t\t\tthis.getDataSource(\"geodata\");\r\n\t\t}\r\n\t\treturn this._dataSources[\"geodata\"];\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeatures(): { \"type\": \"Feature\", geometry: { type: \"Point\" | \"MultiLineString\" | \"MultiPolygon\", coordinates: [number, number] | Array> | Array>> } }[] {\r\n\t\treturn;\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic validateDataItems() {\r\n\t\tsuper.validateDataItems();\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic updateExtremes() {\r\n\t\tlet north: number;\r\n\t\tlet south: number;\r\n\t\tlet east: number;\r\n\t\tlet west: number;\r\n\r\n\t\tthis.dataItems.each((dataItem) => {\r\n\t\t\tif (dataItem.north > north || !$type.isNumber(north)) {\r\n\t\t\t\tnorth = dataItem.north;\r\n\t\t\t}\r\n\r\n\t\t\tif (dataItem.south < south || !$type.isNumber(south)) {\r\n\t\t\t\tsouth = dataItem.south;\r\n\t\t\t}\r\n\r\n\t\t\tif (dataItem.west < west || !$type.isNumber(west)) {\r\n\t\t\t\twest = dataItem.west;\r\n\t\t\t}\r\n\r\n\t\t\tif (dataItem.east > east || !$type.isNumber(east)) {\r\n\t\t\t\teast = dataItem.east;\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\tif (this._mapObjects) {\r\n\t\t\tthis._mapObjects.each((mapObject) => {\r\n\t\t\t\tif (mapObject.north > north || !$type.isNumber(north)) {\r\n\t\t\t\t\tnorth = mapObject.north;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (mapObject.south < south || !$type.isNumber(south)) {\r\n\t\t\t\t\tsouth = mapObject.south;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (mapObject.west < west || !$type.isNumber(west)) {\r\n\t\t\t\t\twest = mapObject.west;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (mapObject.east > east || !$type.isNumber(east)) {\r\n\t\t\t\t\teast = mapObject.east;\r\n\t\t\t\t}\r\n\t\t\t})\r\n\t\t}\r\n\r\n\r\n\t\tif (this.north != north || this.east != east || this.south != south || this.west != west) {\r\n\t\t\tthis._north = north;\r\n\t\t\tthis._east = east;\r\n\t\t\tthis._west = west;\r\n\t\t\tthis._south = south;\r\n\r\n\t\t\tthis.dispatch(\"geoBoundsChanged\");\r\n\t\t\tif (!this.ignoreBounds) {\r\n\t\t\t\tthis.chart.updateExtremes();\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * North-most latitude of the series.\r\n\t *\r\n\t * By default, this holds auto-calculated latitude of the extremity.\r\n\t *\r\n\t * It can be overridden manually.\r\n\t *\r\n\t * @param value Latitude\r\n\t */\r\n\tpublic set north(value: number) {\r\n\t\tthis._northDefined = value;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Latitude\r\n\t */\r\n\tpublic get north(): number {\r\n\t\tif ($type.isNumber(this._northDefined)) {\r\n\t\t\treturn this._northDefined;\r\n\t\t}\r\n\t\treturn this._north;\r\n\t}\r\n\r\n\t/**\r\n\t * South-most latitude of the series.\r\n\t *\r\n\t * By default, this holds auto-calculated latitude of the extremity.\r\n\t *\r\n\t * It can be overridden manually.\r\n\t *\r\n\t * @param value Latitude\r\n\t */\r\n\tpublic set south(value: number) {\r\n\t\tthis._southDefined = value;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Latitude\r\n\t */\r\n\tpublic get south(): number {\r\n\t\tif ($type.isNumber(this._southDefined)) {\r\n\t\t\treturn this._southDefined;\r\n\t\t}\r\n\t\treturn this._south;\r\n\t}\r\n\r\n\t/**\r\n\t * West-most longitude of the series.\r\n\t *\r\n\t * By default, this holds auto-calculated longitude of the extremity.\r\n\t *\r\n\t * It can be overridden manually.\r\n\t *\r\n\t * @param value Longitude\r\n\t */\r\n\tpublic set west(value: number) {\r\n\t\tthis._westDefined = value;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Longitude\r\n\t */\r\n\tpublic get west(): number {\r\n\t\tif ($type.isNumber(this._westDefined)) {\r\n\t\t\treturn this._westDefined;\r\n\t\t}\r\n\t\treturn this._west;\r\n\t}\r\n\r\n\t/**\r\n\t * East-most longitude of the series.\r\n\t *\r\n\t * By default, this holds auto-calculated longitude of the extremity.\r\n\t *\r\n\t * It can be overridden manually.\r\n\t *\r\n\t * @param value Longitude\r\n\t */\r\n\tpublic set east(value: number) {\r\n\t\tthis._eastDefined = value;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Longitude\r\n\t */\r\n\tpublic get east(): number {\r\n\t\tif ($type.isNumber(this._eastDefined)) {\r\n\t\t\treturn this._eastDefined;\r\n\t\t}\r\n\t\treturn this._east;\r\n\t}\r\n\r\n\t/**\r\n\t * Processes JSON-based config before it is applied to the object.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @param config Config\r\n\t */\r\n\tpublic processConfig(config?: { [index: string]: any }): void {\r\n\r\n\t\tif ($type.hasValue(config[\"geodata\"]) && $type.isString(config[\"geodata\"])) {\r\n\t\t\tconst name = config[\"geodata\"];\r\n\t\t\t// Check if there's a map loaded by such name\r\n\t\t\tif ($type.hasValue((window)[\"am4geodata_\" + config[\"geodata\"]])) {\r\n\t\t\t\tconfig[\"geodata\"] = (window)[\"am4geodata_\" + config[\"geodata\"]];\r\n\t\t\t}\r\n\t\t\t// Nope. Let's try maybe we got JSON as string?\r\n\t\t\telse {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tconfig[\"geodata\"] = JSON.parse(config[\"geodata\"]);\r\n\t\t\t\t}\r\n\t\t\t\tcatch (e) {\r\n\t\t\t\t\t// No go again. Error out.\r\n\t\t\t\t\tthrow Error(\"MapChart error: Geodata `\" + name + \"` is not loaded or is incorrect.\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tsuper.processConfig(config);\r\n\t}\r\n\r\n\t/**\r\n\t * Adds `projection` to \"as is\" fields.\r\n\t *\r\n\t * @param field Field name\r\n\t * @return Assign as is?\r\n\t */\r\n\tprotected asIs(field: string): boolean {\r\n\t\treturn field == \"geodata\" || super.asIs(field);\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic updateTooltipBounds() {\r\n\t\tif (this.tooltip && this.topParent) {\r\n\t\t\tthis.tooltip.setBounds({ x: 10, y: 10, width: this.topParent.maxWidth - 20, height: this.topParent.maxHeight - 20 });\r\n\t\t}\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapSeries\"] = MapSeries;\r\nregistry.registeredClasses[\"MapSeriesDataItem\"] = MapSeriesDataItem;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapSeries.ts","/**\r\n * Map object module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Container, IContainerProperties, IContainerAdapters, IContainerEvents } from \"../../core/Container\";\r\nimport { MapSeries, MapSeriesDataItem } from \"./MapSeries\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { IPoint } from \"../../core/defs/IPoint\";\r\nimport * as $math from \"../../core/utils/Math\";\r\nimport * as d3geo from \"d3-geo\";\r\nimport * as $type from \"../../core/utils/Type\";\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines propeties for [[MapObject]].\r\n */\r\nexport interface IMapObjectProperties extends IContainerProperties {\r\n\r\n\t/**\r\n\t * A custom zoom level to use when `zoomToMapObject()` is called on this\r\n\t * map object.\r\n\t */\r\n\tzoomLevel?: number;\r\n\r\n\t/**\r\n\t * A custom point to use when `zoomToMapObject()` is called on this map\r\n\t * object.\r\n\t */\r\n\tzoomGeoPoint?: IGeoPoint;\r\n\r\n}\r\n\r\n/**\r\n * Defines events for [[MapObject]].\r\n */\r\nexport interface IMapObjectEvents extends IContainerEvents {\r\n\tgeoBoundsChanged: {}\r\n}\r\n\r\n/**\r\n * Defines adapters for [[MapObject]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapObjectAdapters extends IContainerAdapters, IMapObjectProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * A base class for all map objects: lines, images, etc.\r\n *\r\n * @see {@link IMapObjectEvents} for a list of available events\r\n * @see {@link IMapObjectAdapters} for a list of available Adapters\r\n */\r\nexport class MapObject extends Container {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapObjectProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapObjectAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapObjectEvents;\r\n\r\n\t/**\r\n\t * A map series this object belongs to.\r\n\t */\r\n\tpublic series: MapSeries;\r\n\r\n\tpublic _dataItem: MapSeriesDataItem;\r\n\r\n\r\n\t/**\r\n\t * Longitude of the East-most point of the element.\r\n\t */\r\n\tprotected _east: number;\r\n\r\n\t/**\r\n\t * Longitude of the West-most point of the element.\r\n\t */\r\n\tprotected _west: number;\r\n\r\n\t/**\r\n\t * Latitude of the South-most point of the element.\r\n\t */\r\n\tprotected _south: number;\r\n\r\n\t/**\r\n\t * Latitude of the North-most point of the element.\r\n\t */\r\n\tprotected _north: number;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapObject\";\r\n\r\n\t\t// Set defaults\r\n\t\tthis.isMeasured = false;\r\n\t\tthis.layout = \"none\";\r\n\t\tthis.clickable = true;\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates this object, forcing it to redraw.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validate(): void {\r\n\t\tif (this.series && this.series.itemReaderText) {\r\n\t\t\tthis.readerTitle = this.series.itemReaderText;\r\n\t\t}\r\n\t\tsuper.validate();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Updates the item's bounding coordinates: coordinates of the East, West,\r\n\t * North, and South-most points.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic updateExtremes(): void {\r\n\t\tlet feature = this.getFeature();\r\n\t\tif (feature) {\r\n\t\t\tlet geometry = feature.geometry;\r\n\r\n\t\t\tif (geometry) {\t\t\t\t\r\n\t\t\t\tlet bounds = d3geo.geoBounds(geometry);\r\n\r\n\t\t\t\tlet west = bounds[0][0];\r\n\t\t\t\tlet south = bounds[0][1];\r\n\r\n\t\t\t\tlet north = bounds[1][1];\r\n\t\t\t\tlet east = bounds[1][0];\r\n\r\n\t\t\t\tlet changed = false;\r\n\t\t\t\tif (north != this.north) {\r\n\t\t\t\t\tthis._north = $math.round(north, 8);\r\n\t\t\t\t\tchanged = true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (south != this.south) {\r\n\t\t\t\t\tthis._south = $math.round(south);\r\n\t\t\t\t\tchanged = true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (east != this.east) {\r\n\t\t\t\t\tthis._east = $math.round(east);\r\n\t\t\t\t\tchanged = true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (west != this.west) {\r\n\t\t\t\t\tthis._west = $math.round(west);\r\n\t\t\t\t\tchanged = true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (changed) {\r\n\t\t\t\t\tthis.dispatch(\"geoBoundsChanged\");\r\n\t\t\t\t\tif(this.series){\r\n\t\t\t\t\t\tthis.series.invalidateDataItems();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeature(): any {\r\n\t\treturn {};\r\n\t}\r\n\r\n\t/**\r\n\t * Longitude of the East-most point of the element.\r\n\t */\r\n\tpublic get east(): number {\r\n\t\tif ($type.isNumber(this._east)) {\r\n\t\t\treturn this._east;\r\n\t\t}\r\n\t\telse if (this.dataItem) {\r\n\t\t\treturn this.dataItem.east;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Longitude of the West-most point of the element.\r\n\t */\r\n\tpublic get west(): number {\r\n\t\tif ($type.isNumber(this._west)) {\r\n\t\t\treturn this._west;\r\n\t\t}\r\n\t\telse if (this.dataItem) {\r\n\t\t\treturn this.dataItem.west;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude of the South-most point of the element.\r\n\t */\r\n\tpublic get south(): number {\r\n\t\tif ($type.isNumber(this._south)) {\r\n\t\t\treturn this._south;\r\n\t\t}\r\n\t\telse if (this.dataItem) {\r\n\t\t\treturn this.dataItem.south;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude of the North-most point of the element.\r\n\t */\r\n\tpublic get north(): number {\r\n\t\tif ($type.isNumber(this._north)) {\r\n\t\t\treturn this._north;\r\n\t\t}\r\n\t\telse if (this.dataItem) {\r\n\t\t\treturn this.dataItem.north;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Shows the element's [[Tooltip]].\r\n\t *\r\n\t * A tooltip will be populated using text templates in either `tooltipHTML` or\r\n\t * `tooltipText` as well as data in `tooltipDataItem`.\r\n\t *\r\n\t * @see {@link Tooltip}\r\n\t * @param optional point (sprite-related) to which tooltip must point.\r\n\t * @return returns true if the tooltip was shown and false if it wasn't (no text was found)\r\n\t */\r\n\tpublic showTooltip(point?: IPoint): boolean {\r\n\t\tconst res = super.showTooltip(point);\r\n\t\tif (res && this.showTooltipOn == \"always\" && !this.series.chart.events.has(\"mappositionchanged\", this.handleTooltipMove, this)) {\r\n\t\t\tthis.addDisposer(this.series.chart.events.on(\"mappositionchanged\", this.handleTooltipMove, this));\r\n\t\t}\r\n\t\treturn res;\r\n\t}\r\n\r\n\tprotected handleTooltipMove(ev: any): void {\r\n\t\tif(!this.tooltip.isHidden){\r\n\t\t\tthis.showTooltip();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Sets a [[DataItem]].\r\n\t * @param dataItem DataItem\r\n\t */\r\n\tprotected setDataItem(dataItem: MapSeriesDataItem) {\r\n\t\tsuper.setDataItem(dataItem);\r\n\t\tthis.applyAccessibility();\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapObject\"] = MapObject;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapObject.ts","/**\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapObject, IMapObjectProperties, IMapObjectAdapters, IMapObjectEvents } from \"./MapObject\";\r\nimport { MapImageSeriesDataItem, MapImageSeries } from \"./MapImageSeries\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport * as $type from \"../../core/utils/Type\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[MapImage]].\r\n */\r\nexport interface IMapImageProperties extends IMapObjectProperties {\r\n\r\n\t/**\r\n\t * Latitude of the image location.\r\n\t */\r\n\tlatitude?: number;\r\n\r\n\t/**\r\n\t * Longitude of the mage location.\r\n\t */\r\n\tlongitude?: number;\r\n\r\n}\r\n\r\n/**\r\n * Defines events for [[MapImage]].\r\n */\r\nexport interface IMapImageEvents extends IMapObjectEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapImage]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapImageAdapters extends IMapObjectAdapters, IMapImageProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Used to place an image on the map.\r\n *\r\n * @see {@link IMapImageEvents} for a list of available events\r\n * @see {@link IMapImageAdapters} for a list of available Adapters\r\n */\r\nexport class MapImage extends MapObject {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapImageProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapImageAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapImageEvents;\r\n\r\n\t/**\r\n\t * A related data item.\r\n\t */\r\n\tpublic _dataItem: MapImageSeriesDataItem;\r\n\r\n\t/**\r\n\t * A map series this object belongs to.\r\n\t */\r\n\tpublic series: MapImageSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\r\n\t\tthis.className = \"MapImage\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude image is placed at.\r\n\t *\r\n\t * @param value Latitude\r\n\t */\r\n\tpublic set latitude(value: number) {\r\n\t\tthis.setPropertyValue(\"latitude\", value, false, true);\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @return Latitude\r\n\t */\r\n\tpublic get latitude(): number {\r\n\t\tlet latitude = this.getPropertyValue(\"latitude\");\r\n\t\t\r\n\t\tif(!$type.isNumber(latitude) && this.dataItem && this.dataItem.geoPoint){\r\n\t\t\tlatitude = this.dataItem.geoPoint.latitude;\r\n\t\t}\t\t\r\n\t\treturn latitude;\t\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * Longitude image is placed on.\r\n\t *\r\n\t * @param value Longitude\r\n\t */\r\n\tpublic set longitude(value: number) {\r\n\t\tthis.setPropertyValue(\"longitude\", value, false, true);\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @return Longitude\r\n\t */\r\n\tpublic get longitude(): number {\r\n\t\tlet longitude = this.getPropertyValue(\"longitude\");\r\n\t\tif(!$type.isNumber(longitude) && this.dataItem && this.dataItem.geoPoint){\r\n\t\t\tlongitude = this.dataItem.geoPoint.longitude;\r\n\t\t}\t\t\r\n\t\treturn longitude;\r\n\t}\r\n\r\n\t/**\r\n\t * Repositions the image to it's current position.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validatePosition(): void {\r\n\t\tif ($type.isNumber(this.latitude) && $type.isNumber(this.longitude)) {\r\n\t\t\t//this.moveTo(this.series.chart.projection.convert({ latitude: this.latitude, longitude: this.longitude }));\r\n\t\t\tlet p = this.series.chart.projection.d3Projection([this.longitude, this.latitude]);\r\n\r\n\t\t\tlet visible: any = this.series.chart.projection.d3Path({ type: 'Point', coordinates: [this.longitude, this.latitude] });\r\n\r\n\t\t\tif (!visible) {\r\n\t\t\t\tthis.__disabled = true;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.__disabled = false;\r\n\t\t\t}\r\n\r\n\t\t\tthis.moveTo({ x: p[0], y: p[1] });\r\n\t\t}\r\n\t\tsuper.validatePosition();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeature(): { \"type\": \"Feature\", geometry: { type: \"Point\", coordinates: [number, number] } } {\r\n\t\treturn { \"type\": \"Feature\", geometry: { type: \"Point\", coordinates: [this.longitude, this.latitude] } };\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapImage\"] = MapImage;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapImage.ts","/**\r\n * A collection of Map-related utility functions.\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport * as $array from \"../../core/utils/Array\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n/**\r\n * Converts a multi-part polygon in X/Y coordinates to a geo-multipolygon in\r\n * geo-points (lat/long).\r\n *\r\n * @param multiPolygon Source multi-polygon\r\n * @return Geo-multipolygon\r\n */\r\n\r\nexport function multiPolygonToGeo(multiPolygon: Array<[Array<[number, number]>, Array<[number, number]>]>): Array>> {\r\n\treturn $array.map(multiPolygon, (polygon) => {\r\n\t\tlet surface: Array<[number, number]> = polygon[0];\r\n\t\tlet hole: Array<[number, number]> = polygon[1];\r\n\r\n\t\t//let holePoints: Array = [];\r\n\r\n\t\tconst geoArea = [];\r\n\r\n\t\tif (surface) {\r\n\t\t\tgeoArea.push(multiPointToGeo(surface));\r\n\t\t}\r\n\r\n\t\tif (hole) {\r\n\t\t\tgeoArea.push(multiPointToGeo(hole));\r\n\t\t}\r\n\r\n\t\treturn geoArea;\r\n\t});\r\n}\r\n\r\n/**\r\n * Converts a multiline in X/Y coordinates to a geo-multiline in geo-points\r\n * (lat/long).\r\n *\r\n * @param multiLine Source multiline\r\n * @return Geo-multiline\r\n */\r\nexport function multiLineToGeo(multiLine: Array>): Array> {\r\n\treturn $array.map(multiLine, (multiLine) => {\r\n\t\treturn multiPointToGeo(multiLine);\r\n\t});\r\n}\r\n\r\n/**\r\n * Converts multiple X/Y points into a lat/long geo-points.\r\n *\r\n * @param points Source points\r\n * @return Geo-points\r\n */\r\nexport function multiPointToGeo(points: Array<[number, number]>): Array {\r\n\treturn $array.map(points, (point) => {\r\n\t\treturn pointToGeo(point);\r\n\t});\r\n}\r\n\r\n\r\n/**\r\n * Converts multiple X/Y points into a lat/long geo-points.\r\n *\r\n * @param points Source points\r\n * @return Geo-points\r\n */\r\nexport function multiGeoToPoint(geoPoints: Array): Array<[number, number]> {\r\n\treturn $array.map(geoPoints, geoToPoint);\r\n}\r\n\r\n\r\n/**\r\n * Converts X/Y point into a lat/long geo-point.\r\n *\r\n * @param point Source point\r\n * @return Geo-point\r\n */\r\nexport function pointToGeo(point: [number, number]): IGeoPoint {\r\n\treturn { longitude: point[0], latitude: point[1] }\r\n}\r\n\r\n/**\r\n * Converts lat/long geo-point into a X/Y point.\r\n *\r\n * @param point Source geo-point\r\n * @return X/Y point\r\n */\r\nexport function geoToPoint(geoPoint: IGeoPoint): [number, number] {\r\n\treturn [geoPoint.longitude, geoPoint.latitude];\r\n}\r\n\r\n\r\n/**\r\n * Converts geo line (collection of lat/long coordinates) to screen line (x/y).\r\n *\r\n * @param multiGeoLine Source geo line\r\n * @return Screen line\r\n */\r\nexport function multiGeoLineToMultiLine(multiGeoLine: Array>): Array> {\r\n\treturn $array.map(multiGeoLine, (segment) => {\r\n\t\treturn $array.map(segment, geoToPoint);\r\n\t});\r\n}\r\n\r\n/**\r\n * Converts a geo polygon (collection of lat/long coordinates) to screen\r\n * polygon (x/y).\r\n *\r\n * @param multiGeoPolygon Source polygon\r\n * @return Screen polygon\r\n */\r\nexport function multiGeoPolygonToMultipolygon(multiGeoPolygon: Array<[Array, Array]>): Array>> {\r\n\treturn $array.map(multiGeoPolygon, (geoPolygon) => {\r\n\t\tlet surface = geoPolygon[0];\r\n\t\tlet hole = geoPolygon[1];\r\n\r\n\t\tconst multiPolygon = [];\r\n\r\n\t\tif (surface) {\r\n\t\t\tmultiPolygon.push(multiGeoToPoint(surface));\r\n\t\t}\r\n\r\n\t\tif (hole) {\r\n\t\t\tmultiPolygon.push(multiGeoToPoint(hole));\r\n\t\t}\r\n\r\n\t\treturn multiPolygon;\r\n\t});\r\n}\r\n\r\n/**\r\n * Returns a set of geographical coordinates for the circle with a center\r\n * at specific lat/long coordinates and radius (in degrees).\r\n *\r\n * @since 4.3.0\r\n * @param longitude Center longitude\r\n * @param latitude Center latitude\r\n * @param radius Radius (degrees)\r\n * @return Circle coordinates\r\n */\r\nexport function getCircle(longitude: number, latitude: number, radius: number): Array>> {\r\n\treturn [d3geo.geoCircle().center([longitude, latitude]).radius(radius)().coordinates as Array>];\r\n}\r\n\r\n/**\r\n * Returns a set of screen coordinates that represents a \"background\" area\r\n * between provided extremities.\r\n *\r\n * @since 4.3.0\r\n * @param north North latitude\r\n * @param east East longitude\r\n * @param south South latitude\r\n * @param west West longitude\r\n * @return Polygon\r\n */\r\nexport function getBackground(north: number, east: number, south: number, west: number): Array>> {\r\n\r\n\tlet multiPolygon: Array>> = [];\r\n\r\n\tif(west == -180){\r\n\t\twest = -179.9999;\r\n\t}\r\n\tif(south == -90){\r\n\t\tsouth = -89.9999;\r\n\t}\r\n\tif(north == 90){\r\n\t\tnorth = 89.9999;\r\n\t}\r\n\tif(east == 180){\r\n\t\teast = 179.9999;\r\n\t}\r\n\r\n\r\n\tlet stepLong = Math.min(90, (east - west) / Math.ceil((east - west) / 90));\r\n\tlet stepLat = (north - south) / Math.ceil((north - south) / 90);\r\n\r\n\tfor (let ln = west; ln < east; ln = ln + stepLong) {\r\n\t\tlet surface: Array<[number, number]> = [];\r\n\t\tmultiPolygon.push([surface]);\r\n\r\n\t\tif(ln + stepLong > east){\r\n\t\t\tstepLong = east - ln;\r\n\t\t}\r\n\r\n\t\tfor (let ll = ln; ll <= ln + stepLong; ll = ll + 5) {\r\n\t\t\tsurface.push([ll, north]);\r\n\t\t}\r\n\r\n\t\tfor (let lt = north; lt >= south; lt = lt - stepLat) {\r\n\t\t\tsurface.push([ln + stepLong, lt]);\r\n\t\t}\r\n\r\n\t\tfor (let ll = ln + stepLong; ll >= ln; ll = ll - 5) {\r\n\t\t\tsurface.push([ll, south]);\r\n\t\t}\r\n\r\n\t\tfor (let lt = south; lt <= north; lt = lt + stepLat) {\r\n\t\t\tsurface.push([ln, lt]);\r\n\t\t}\r\n\r\n\r\n\t}\r\n\r\n\treturn multiPolygon;\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapUtils.ts","/**\r\n * Map polygon module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapObject, IMapObjectProperties, IMapObjectAdapters, IMapObjectEvents } from \"./MapObject\";\r\nimport { MapPolygonSeriesDataItem, MapPolygonSeries } from \"./MapPolygonSeries\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { Polygon } from \"../../core/elements/Polygon\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport * as $type from \"../../core/utils/Type\";\r\nimport { InterfaceColorSet } from \"../../core/utils/InterfaceColorSet\";\r\nimport $polylabel from \"polylabel\";\r\nimport * as $mapUtils from \"./MapUtils\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[MapPolygon]].\r\n */\r\nexport interface IMapPolygonProperties extends IMapObjectProperties {\r\n\r\n\t/**\r\n\t * Set of geographical coordinates for the polygon.\r\n\t */\r\n\tmultiGeoPolygon?: Array<[Array, Array]>;\r\n\r\n\t/**\r\n\t * Set of screen coordinates for the polygon.\r\n\t */\r\n\tmultiPolygon?: Array>>;\r\n\r\n\t/**\r\n\t * Latitude of the visual center of the polygon.\r\n\t */\r\n\tvisualLatitude?: number;\r\n\r\n\t/**\r\n\t * Longitude of the visual center of the polygon.\r\n\t */\r\n\tvisualLongitude?: number;\r\n\r\n\t/**\r\n\t * When polygon's sides are plotted, they are bent according to the used\r\n\t * projection, to depict the shortest distance how it would go on the actual\r\n\t * land.\r\n\t *\r\n\t * `precision` introduces a setting which can control when such bending\r\n\t * occurs.\r\n\t *\r\n\t * If the distance (in degrees) between two points of polygon's side is less\r\n\t * than `precision`, no bending will take place and the line will be straight.\r\n\t *\r\n\t * Set to large number (e.g. 10000) for perfectly straight lines on all\r\n\t * polygon's sides.\r\n\t *\r\n\t * @since 4.9.1\r\n\t * @default 0.5\r\n\t */\r\n\tprecision?: number;\r\n}\r\n\r\n/**\r\n * Defines events for [[MapPolygon]].\r\n */\r\nexport interface IMapPolygonEvents extends IMapObjectEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapPolygon]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapPolygonAdapters extends IMapObjectAdapters, IMapPolygonProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Used to draw a polygon on the map.\r\n *\r\n * @see {@link IMapPolygonEvents} for a list of available events\r\n * @see {@link IMapPolygonAdapters} for a list of available Adapters\r\n */\r\nexport class MapPolygon extends MapObject {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapPolygonProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapPolygonAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapPolygonEvents;\r\n\r\n\t/**\r\n\t * A visual polygon element.\r\n\t */\r\n\tpublic polygon: Polygon;\r\n\r\n\t/**\r\n\t * A related data item.\r\n\t */\r\n\tpublic _dataItem: MapPolygonSeriesDataItem;\r\n\r\n\t/**\r\n\t * A map series this object belongs to.\r\n\t */\r\n\tpublic series: MapPolygonSeries;\r\n\r\n\t/**\r\n\t * Latitude of the visual center of the polygon.\r\n\t */\r\n\tprotected _visualLatitude: number;\r\n\r\n\t/**\r\n\t * Longitude of the visual center of the polygon.\r\n\t */\r\n\tprotected _visualLongitude: number;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\r\n\t\tthis.className = \"MapPolygon\";\r\n\r\n\t\tthis.polygon = this.createChild(Polygon);\r\n\t\tthis.polygon.shouldClone = false;\r\n\t\tthis.polygon.applyOnClones = true;\r\n\t\tthis.setPropertyValue(\"precision\", 0.5);\r\n\r\n\t\tlet interfaceColors = new InterfaceColorSet();\r\n\r\n\t\tthis.fill = interfaceColors.getFor(\"secondaryButton\");\r\n\t\tthis.stroke = interfaceColors.getFor(\"secondaryButtonStroke\");\r\n\t\tthis.strokeOpacity = 1;\r\n\r\n\t\tthis.tooltipPosition = \"pointer\";\r\n\r\n\t\tthis.nonScalingStroke = true;\r\n\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeature(): { \"type\": \"Feature\", geometry: { type: \"MultiPolygon\", coordinates: Array>> } } {\r\n\t\tif (this.multiPolygon && this.multiPolygon.length > 0) {\r\n\t\t\treturn { \"type\": \"Feature\", geometry: { type: \"MultiPolygon\", coordinates: this.multiPolygon } };\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Set of coordinates for the polygon.\r\n\t *\r\n\t * @param multiGeoPolygon Polygon coordinates\r\n\t */\r\n\tpublic set multiGeoPolygon(multiGeoPolygon: Array<[Array, Array]>) {\r\n\t\tthis.setPropertyValue(\"multiGeoPolygon\", multiGeoPolygon, true);\r\n\t\tthis.multiPolygon = $mapUtils.multiGeoPolygonToMultipolygon(multiGeoPolygon);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Polygon coordinates\r\n\t */\r\n\tpublic get multiGeoPolygon(): Array<[Array, Array]> {\r\n\t\tlet multiGeoPolygon = this.getPropertyValue(\"multiGeoPolygon\");\r\n\t\tif (!multiGeoPolygon && this.dataItem) {\r\n\t\t\tmultiGeoPolygon = this.dataItem.multiGeoPolygon;\r\n\t\t}\r\n\t\treturn multiGeoPolygon;\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-part polygon. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * // Part 1\r\n\t * [\r\n\t * [\r\n\t * [ 100, 150 ],\r\n\t * [ 120, 200 ],\r\n\t * [ 150, 220 ],\r\n\t * [ 170, 240 ],\r\n\t * [ 100, 150 ]\r\n\t * ]\r\n\t * ],\r\n\t *\r\n\t * // Part 2\r\n\t * [\r\n\t * [\r\n\t * [ 300, 350 ],\r\n\t * [ 320, 400 ],\r\n\t * [ 350, 420 ],\r\n\t * [ 370, 440 ],\r\n\t * [ 300, 350 ]\r\n\t * ]\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @param multiPolygon Coordinates\r\n\t */\r\n\tpublic set multiPolygon(multiPolygon: Array>>) {\r\n\t\tif (this.setPropertyValue(\"multiPolygon\", multiPolygon)) {\r\n\t\t\tthis.updateExtremes();\r\n\t\t\tthis.invalidate();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get multiPolygon(): Array>> {\r\n\t\tlet multiPolygon = this.getPropertyValue(\"multiPolygon\");\r\n\t\tif (!multiPolygon && this.dataItem) {\r\n\t\t\tmultiPolygon = this.dataItem.multiPolygon;\r\n\t\t}\r\n\t\treturn multiPolygon;\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * (Re)validates the polygon, effectively redrawing it.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validate(): void {\r\n\t\tif (this.series) {\r\n\t\t\tlet projection = this.series.chart.projection;\r\n\r\n\t\t\tlet pathGenerator = projection.d3Path;\r\n\r\n\t\t\tif (this.multiPolygon) {\r\n\r\n\t\t\t\tif (this.series) {\r\n\t\t\t\t\tlet feature = { type: \"MultiPolygon\", coordinates: this.multiPolygon };\r\n\r\n\t\t\t\t\tprojection.d3Projection.precision(this.precision);\r\n\t\t\t\t\tthis.polygon.path = pathGenerator(feature);\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (this.series.calculateVisualCenter) {\r\n\t\t\t\t\tlet biggestArea = 0;\r\n\t\t\t\t\tlet biggestPolygon = this.multiPolygon[0];\r\n\r\n\t\t\t\t\tif (this.multiPolygon.length > 1) {\r\n\t\t\t\t\t\tfor (let i = 0; i < this.multiPolygon.length; i++) {\r\n\t\t\t\t\t\t\tlet polygon = this.multiPolygon[i];\r\n\t\t\t\t\t\t\tlet area = d3geo.geoArea({ type: \"Polygon\", coordinates: polygon });\r\n\r\n\t\t\t\t\t\t\tif (area > biggestArea) {\r\n\t\t\t\t\t\t\t\tbiggestPolygon = polygon;\r\n\t\t\t\t\t\t\t\tbiggestArea = area;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tlet center = $polylabel(biggestPolygon);\r\n\r\n\t\t\t\t\tthis._visualLongitude = center[0];\r\n\t\t\t\t\tthis._visualLatitude = center[1];\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tthis._visualLongitude = this.longitude;\r\n\t\t\t\t\tthis._visualLatitude = this.latitude;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tsuper.validate();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic measureElement(): void {\r\n\t\t// Overriding, just to avoid extra measure\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude of the geometrical center of the polygon.\r\n\t *\r\n\t * @readonly\r\n\t * @return Center latitude\r\n\t */\r\n\tpublic get latitude(): number {\r\n\t\treturn this.north + (this.south - this.north) / 2;\r\n\t}\r\n\r\n\t/**\r\n\t * Longitude of the geometrical center of the polygon.\r\n\t *\r\n\t * @readonly\r\n\t * @return Center longitude\r\n\t */\r\n\tpublic get longitude(): number {\r\n\t\treturn this.east + (this.west - this.east) / 2;\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude of the visual center of the polygon.\r\n\t *\r\n\t * It may (and probably won't) coincide with geometrical center.\r\n\t *\r\n\t * @since 4.3.0\r\n\t * @param value Latitude\r\n\t */\r\n\tpublic set visualLatitude(value: number) {\r\n\t\tthis.setPropertyValue(\"visualLatitude\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Latitude\r\n\t */\r\n\tpublic get visualLatitude(): number {\r\n\t\tlet latitude = this.getPropertyValue(\"visualLatitude\");\r\n\t\tif ($type.isNumber(latitude)) {\r\n\t\t\treturn (latitude);\r\n\t\t}\r\n\t\tif (!this._adapterO) {\r\n\t\t\treturn this._visualLatitude;\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn this._adapterO.apply(\r\n\t\t\t\t\"visualLatitude\",\r\n\t\t\t\tthis._visualLatitude\r\n\t\t\t);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Longitude of the visual center of the polygon.\r\n\t *\r\n\t * It may (and probably won't) coincide with geometrical center.\r\n\t *\r\n\t * @since 4.3.0\r\n\t * @param value Longitude\r\n\t */\r\n\tpublic set visualLongitude(value: number) {\r\n\t\tthis.setPropertyValue(\"visualLongitude\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Longitude\r\n\t */\r\n\tpublic get visualLongitude(): number {\r\n\t\tlet longitude = this.getPropertyValue(\"visualLongitude\");\r\n\t\tif ($type.isNumber(longitude)) {\r\n\t\t\treturn (longitude);\r\n\t\t}\r\n\t\tif (!this._adapterO) {\r\n\t\t\treturn this._visualLongitude;\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn this._adapterO.apply(\r\n\t\t\t\t\"visualLongitude\",\r\n\t\t\t\tthis._visualLongitude\r\n\t\t\t);\r\n\t\t}\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Not 100% sure about this, as if we add something to MapPolygon this\r\n\t * won't be true, but otherwise we will get all 0 and the tooltip won't\r\n\t * be positioned properly\r\n\t * @hidden\r\n\t */\r\n\r\n\t/**\r\n\t * Element's width in pixels.\r\n\t *\r\n\t * @readonly\r\n\t * @return Width (px)\r\n\t */\r\n\tpublic get pixelWidth(): number {\r\n\t\treturn this.polygon.pixelWidth;\r\n\t}\r\n\r\n\t/**\r\n\t * Element's height in pixels.\r\n\t *\r\n\t * @readonly\r\n\t * @return Width (px)\r\n\t */\r\n\tpublic get pixelHeight(): number {\r\n\t\treturn this.polygon.pixelHeight;\r\n\t}\r\n\r\n\t/**\r\n\t * Copies all properties from another instance of [[MapPolygon]].\r\n\t *\r\n\t * @param source Source series\r\n\t */\r\n\tpublic copyFrom(source: this) {\r\n\t\tsuper.copyFrom(source);\r\n\t\tthis.polygon.copyFrom(source.polygon);\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic updateExtremes() {\r\n\t\tsuper.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t * used to sorth polygons from big to small\r\n\t */\r\n\tpublic get boxArea() {\r\n\t\treturn (this.north - this.south) * (this.east - this.west);\r\n\t}\r\n\r\n\t/**\r\n\t * X coordinate for the slice tooltip.\r\n\t *\r\n\t * @ignore\r\n\t * @return X\r\n\t */\r\n\tpublic getTooltipX(): number {\r\n\t\treturn this.series.chart.projection.convert({ longitude: this.visualLongitude, latitude: this.visualLatitude }).x;\r\n\t}\r\n\r\n\t/**\r\n\t * Y coordinate for the slice tooltip.\r\n\t *\r\n\t * @ignore\r\n\t * @return Y\r\n\t */\r\n\tpublic getTooltipY(): number {\r\n\t\treturn this.series.chart.projection.convert({ longitude: this.visualLongitude, latitude: this.visualLatitude }).y\r\n\t}\r\n\r\n\t/**\r\n\t * When polygon's sides are plotted, they are bent according to the used\r\n\t * projection.\r\n\t *\r\n\t * `precision` introduces a setting which can control when such bending\r\n\t * occurs.\r\n\t *\r\n\t * If the distance (in degrees) between two points of polygon's side is less\r\n\t * than `precision`, no bending will take place and the line will be straight.\r\n\t *\r\n\t * Set to large number (e.g. 10000) for perfectly straight lines on all\r\n\t * polygon's sides.\r\n\t *\r\n\t * @since 4.9.1\r\n\t * @default 0.5\r\n\t * @param value Precision\r\n\t */\r\n\tpublic set precision(value: number) {\r\n\t\tthis.setPropertyValue(\"precision\", value, true);\r\n\t}\r\n\r\n\tpublic get precision(): number {\r\n\t\treturn this.getPropertyValue(\"precision\");\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapPolygon\"] = MapPolygon;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapPolygon.ts","/**\r\n * Map polygon series module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapSeries, MapSeriesDataItem, GEOJSONGeometry, IMapSeriesProperties, IMapSeriesDataFields, IMapSeriesAdapters, IMapSeriesEvents } from \"./MapSeries\";\r\nimport { MapChart } from \"../types/MapChart\";\r\nimport { MapPolygon } from \"./MapPolygon\";\r\nimport { ListTemplate, ListDisposer } from \"../../core/utils/List\";\r\nimport { IMapPolygonDataObject } from \"../types/MapChart\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport * as $mapUtils from \"./MapUtils\";\r\nimport * as $array from \"../../core/utils/Array\";\r\nimport * as $utils from \"../../core/utils/Utils\";\r\nimport * as $iter from \"../../core/utils/Iterator\";\r\nimport { Disposer } from \"../../core/utils/Disposer\";\r\nimport { Ordering } from \"../../core/utils/Order\";\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[MapPolygonSeries]]\r\n * @see {@link DataItem}\r\n */\r\nexport class MapPolygonSeriesDataItem extends MapSeriesDataItem {\r\n\r\n\t/**\r\n\t * A [[MapPolygon]] element related to this data item.\r\n\t */\r\n\tprotected _mapPolygon: MapPolygon;\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a single polygon.\r\n\t */\r\n\tprotected _polygon: Array>;\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-part polygon.\r\n\t */\r\n\tprotected _multiPolygon: Array>>;\r\n\r\n\t/**\r\n\t * A collection of lat/long coordinates for a single polygon.\r\n\t */\r\n\tprotected _geoPolygon: [Array, Array];\r\n\r\n\t/**\r\n\t * A collection of lat/long coordinates for a multi-part polygon.\r\n\t */\r\n\tprotected _multiGeoPolygon: Array<[Array, Array]>;\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for\r\n\t */\r\n\tpublic _component!: MapPolygonSeries;\r\n\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapPolygonSeriesDataItem\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeature(): { \"type\": \"Feature\", geometry: { type: \"MultiPolygon\", coordinates: Array>> } } {\r\n\t\tif (this.multiPolygon && this.multiPolygon.length > 0) {\r\n\t\t\treturn { \"type\": \"Feature\", geometry: { type: \"MultiPolygon\", coordinates: this.multiPolygon } };\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * A [[MapPolygon]] element related to this data item.\r\n\t *\r\n\t * @readonly\r\n\t * @return Element\r\n\t */\r\n\tpublic get mapPolygon(): MapPolygon {\r\n\t\tif (!this._mapPolygon) {\r\n\t\t\tlet mapPolygon = this.component.mapPolygons.create();\r\n\t\t\tthis._mapPolygon = mapPolygon;\r\n\t\t\tthis.addSprite(mapPolygon);\r\n\r\n\t\t\tthis._disposers.push(new Disposer(() => {\r\n\t\t\t\tif (this.component) {\r\n\t\t\t\t\tthis.component.mapPolygons.removeValue(mapPolygon);\r\n\t\t\t\t}\r\n\t\t\t}));\r\n\r\n\t\t\tthis.mapObject = mapPolygon;\r\n\t\t}\r\n\t\treturn this._mapPolygon;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a single polygon. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * [\r\n\t * [ 100, 150 ],\r\n\t * [ 120, 200 ],\r\n\t * [ 150, 200 ],\r\n\t * [ 170, 240 ],\r\n\t * [ 100, 150 ]\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @param polygon Coordinates\r\n\t */\r\n\tpublic set polygon(polygon: Array>) {\r\n\t\tthis._polygon = polygon;\r\n\t\tthis.multiPolygon = [polygon];\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get polygon(): Array> {\r\n\t\treturn this._polygon;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-part polygon. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * // Part 1\r\n\t * [\r\n\t * [\r\n\t * [ 100, 150 ],\r\n\t * [ 120, 200 ],\r\n\t * [ 150, 220 ],\r\n\t * [ 170, 240 ],\r\n\t * [ 100, 150 ]\r\n\t * ]\r\n\t * ],\r\n\t *\r\n\t * // Part 2\r\n\t * [\r\n\t * [\r\n\t * [ 300, 350 ],\r\n\t * [ 320, 400 ],\r\n\t * [ 350, 420 ],\r\n\t * [ 370, 440 ],\r\n\t * [ 300, 350 ]\r\n\t * ]\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @param multiPolygon Coordinates\r\n\t */\r\n\tpublic set multiPolygon(multiPolygon: Array>>) {\r\n\t\tthis._multiPolygon = multiPolygon;\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get multiPolygon(): Array>> {\r\n\t\treturn this._multiPolygon;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of lat/long coordinates for a single polygon. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * [\r\n\t * { latitude: -10.0, longitude: -10.0 },\r\n\t * { latitude: 10.0, longitude: -10.0 },\r\n\t * { latitude: 10.0, longitude: 10.0 },\r\n\t * { latitude: -10.0, longitude: -10.0 }\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @see {@link https://tools.ietf.org/html/rfc7946#section-3.1.6} GeoJSON Polygon reference\r\n\t * @param geoPolygon Coordinates\r\n\t */\r\n\tpublic set geoPolygon(geoPolygon: [Array, Array]) {\r\n\t\tthis._geoPolygon = geoPolygon;\r\n\t\tthis.multiGeoPolygon = [geoPolygon];\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get geoPolygon(): [Array, Array] {\r\n\t\treturn this._geoPolygon;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of lat/long coordinates for a multi-part polygon. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * [\r\n\t * [\r\n\t * { longitude: 180.0, latitude: 40.0 },\r\n\t * { longitude: 180.0, latitude: 50.0 },\r\n\t * { longitude: 170.0, latitude: 50.0 },\r\n\t * { longitude: 170.0, latitude: 40.0 },\r\n\t * { longitude: 180.0, latitude: 40.0 }\r\n\t * ]\r\n\t * ],\r\n\t * [\r\n\t * [\r\n\t * { longitude: -170.0, latitude: 40.0 },\r\n\t * { longitude: -170.0, latitude: 50.0 },\r\n\t * { longitude: -180.0, latitude: 50.0 },\r\n\t * { longitude: -180.0, latitude: 40.0 },\r\n\t * { longitude: -170.0, latitude: 40.0 }\r\n\t * ]\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @see {@link https://tools.ietf.org/html/rfc7946#section-3.1.7} GeoJSON MultiPolygon reference\r\n\t * @param multiGeoPolygon Coordinates\r\n\t */\r\n\tpublic set multiGeoPolygon(multiGeoPolygon: Array<[Array, Array]>) {\r\n\t\tthis._multiGeoPolygon = multiGeoPolygon;\r\n\t\tthis.multiPolygon = $mapUtils.multiGeoPolygonToMultipolygon(multiGeoPolygon);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get multiGeoPolygon(): Array<[Array, Array]> {\r\n\t\treturn this._multiGeoPolygon;\r\n\t}\r\n\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines data fields for [[MapPolygonSeries]].\r\n */\r\nexport interface IMapPolygonSeriesDataFields extends IMapSeriesDataFields {\r\n\r\n\t/**\r\n\t * Field name that holds polygon pixels.\r\n\t */\r\n\tpolygon?: string;\r\n\r\n\t/**\r\n\t * Field name that holds multi-polygon pixels.\r\n\t */\r\n\tmultiPolygon?: string;\r\n\r\n\t/**\r\n\t * Field name that holds polygon data in Geo coordinates.\r\n\t */\r\n\tgeoPolygon?: string;\r\n\r\n\t/**\r\n\t * Field name that holds poly-polygon data in Geo coordinates.\r\n\t */\r\n\tmultiGeoPolygon?: string;\r\n\r\n}\r\n\r\n/**\r\n * Defines properties for [[MapPolygonSeries]].\r\n */\r\nexport interface IMapPolygonSeriesProperties extends IMapSeriesProperties {\r\n\r\n\t/**\r\n\t * How to order polygons in actual SVG document. Affects selection order\r\n\t * using TAB key.\r\n\t *\r\n\t * @since 4.9.36\r\n\t */\r\n\tsortPolygonsBy: \"area\" | \"name\" | \"longitude\" | \"latitude\" | \"id\" | \"none\";\r\n\r\n\t/**\r\n\t * If `sortPolygonsBy` is set to something other than `\"none\"`, polygons\r\n\t * will be sorted by the given parameter, using natural sort direction.\r\n\t *\r\n\t * Setting `sortPolygonsReversed = true` will reverse this direction.\r\n\t *\r\n\t * @since 4.9.36\r\n\t */\r\n\tsortPolygonsReversed: boolean;\r\n\r\n}\r\n\r\n/**\r\n * Defines events for [[MapPolygonSeries]].\r\n */\r\nexport interface IMapPolygonSeriesEvents extends IMapSeriesEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapPolygonSeries]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapPolygonSeriesAdapters extends IMapSeriesAdapters, IMapPolygonSeriesProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * A series of map polygon elements.\r\n *\r\n * @see {@link IMapPolygonSeriesEvents} for a list of available Events\r\n * @see {@link IMapPolygonSeriesAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class MapPolygonSeries extends MapSeries {\r\n\r\n\t/**\r\n\t * Defines available data fields.\r\n\t */\r\n\tpublic _dataFields: IMapPolygonSeriesDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapPolygonSeriesProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapPolygonSeriesAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapPolygonSeriesEvents;\r\n\r\n\t/**\r\n\t * Defines the type of data item.\r\n\t */\r\n\tpublic _dataItem: MapPolygonSeriesDataItem;\r\n\r\n\t/**\r\n\t * A related chart/map object, this element is drawn on.\r\n\t */\r\n\tpublic chart: MapChart;\r\n\r\n\t/**\r\n\t * A list of map polygons in the series.\r\n\t */\r\n\tprotected _mapPolygons: ListTemplate;\r\n\r\n\t/**\r\n\t * Indicates if series should automatically calculate visual center of the\r\n\t * polygons (accessible via `visualLongitude` and `visualLatitude` properties\r\n\t * of the [[MapPolygon]]).\r\n\t *\r\n\t * @default false\r\n\t * @since 4.3.0\r\n\t */\r\n\tpublic calculateVisualCenter: boolean = false;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\r\n\t\tthis.className = \"MapPolygonSeries\";\r\n\r\n\t\t// Set data fields\r\n\t\tthis.dataFields.multiPolygon = \"multiPolygon\";\r\n\t\tthis.dataFields.polygon = \"polygon\";\r\n\r\n\t\tthis.dataFields.geoPolygon = \"geoPolygon\";\r\n\t\tthis.dataFields.multiGeoPolygon = \"multiGeoPolygon\";\r\n\r\n\t\tthis.setPropertyValue(\"sortPolygonsBy\", \"area\");\r\n\t\tthis.setPropertyValue(\"sortPolygonsReversed\", false);\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new/empty DataItem of the type appropriate for this object.\r\n\t *\r\n\t * @see {@link DataItem}\r\n\t * @return Data Item\r\n\t */\r\n\tprotected createDataItem(): this[\"_dataItem\"] {\r\n\t\treturn new MapPolygonSeriesDataItem();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected processIncExc() {\r\n\t\tthis.mapPolygons.clear();\r\n\t\tsuper.processIncExc();\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates series data, effectively causing the whole series to be\r\n\t * redrawn.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validateData(): void {\r\n\t\t// process geoJSON and created map objects\r\n\t\tif (this.useGeodata || this.geodata) {\r\n\t\t\tlet geoJSON: any = !this._dataSources[\"geodata\"] ? this.chart.geodata : undefined;\r\n\r\n\t\t\tif (this.geodata) {\r\n\t\t\t\tgeoJSON = this.geodata;\r\n\t\t\t}\r\n\r\n\t\t\tif (geoJSON) {\r\n\r\n\t\t\t\tlet features: any[];\r\n\r\n\t\t\t\tif (geoJSON.type == \"FeatureCollection\") {\r\n\t\t\t\t\tfeatures = geoJSON.features;\r\n\t\t\t\t}\r\n\t\t\t\telse if (geoJSON.type == \"Feature\") {\r\n\t\t\t\t\tfeatures = [geoJSON];\r\n\t\t\t\t}\r\n\t\t\t\telse if ([\"Point\", \"LineString\", \"Polygon\", \"MultiPoint\", \"MultiLineString\", \"MultiPolygon\"].indexOf(geoJSON.type) != -1) {\r\n\t\t\t\t\tfeatures = [{ geometry: geoJSON }];\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tconsole.log(\"nothing found in geoJSON\");\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (features) {\r\n\t\t\t\t\tfor (let i = 0, len = features.length; i < len; i++) {\r\n\t\t\t\t\t\tlet feature: any = features[i];\r\n\t\t\t\t\t\tlet geometry: any = feature.geometry;\r\n\r\n\t\t\t\t\t\tif (geometry) {\r\n\t\t\t\t\t\t\tlet type: GEOJSONGeometry = geometry.type;\r\n\t\t\t\t\t\t\tlet id: string = feature.id;\r\n\r\n\t\t\t\t\t\t\tif (this.chart.geodataNames && this.chart.geodataNames[id]) {\r\n\t\t\t\t\t\t\t\tfeature.properties.name = this.chart.geodataNames[id];\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tif (type == \"Polygon\" || type == \"MultiPolygon\") {\r\n\r\n\t\t\t\t\t\t\t\tif (!this.checkInclude(this.include, this.exclude, id)) {\r\n\t\t\t\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tlet coordinates: any[] = geometry.coordinates;\r\n\r\n\t\t\t\t\t\t\t\tif (coordinates) {\r\n\t\t\t\t\t\t\t\t\t// make the same as MultiPolygon\r\n\t\t\t\t\t\t\t\t\tif (type == \"Polygon\") {\r\n\t\t\t\t\t\t\t\t\t\tcoordinates = [coordinates];\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\t// find data object in user-provided data\r\n\t\t\t\t\t\t\t\tlet dataObject: IMapPolygonDataObject = $array.find(this.data, (value, i) => {\r\n\t\t\t\t\t\t\t\t\treturn value.id == id;\r\n\t\t\t\t\t\t\t\t});\r\n\r\n\r\n\t\t\t\t\t\t\t\t// create one if not found\r\n\t\t\t\t\t\t\t\tif (!dataObject) {\r\n\t\t\t\t\t\t\t\t\tdataObject = { multiPolygon: coordinates, id: id, madeFromGeoData: true };\r\n\t\t\t\t\t\t\t\t\tthis.data.push(dataObject);\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t// in case found\r\n\t\t\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t\t\t// if user-provided object doesn't have points data provided in any way:\r\n\t\t\t\t\t\t\t\t\tif (!dataObject.multiPolygon) {\r\n\t\t\t\t\t\t\t\t\t\tdataObject.multiPolygon = coordinates;\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\t// copy properties data to datacontext\r\n\t\t\t\t\t\t\t\t$utils.softCopyProperties(feature.properties, dataObject);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tsuper.validateData();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * (Re)validates the series\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validate() {\r\n\t\tsuper.validate();\r\n\r\n\t\tthis.dataItems.each((dataItem) => {\r\n\t\t\t$utils.used(dataItem.mapPolygon);\r\n\t\t});\r\n\r\n\t\tif (this.sortPolygonsBy != \"none\") {\r\n\r\n\t\t\tconst sortBy = this.sortPolygonsBy;\r\n\t\t\tconst reversed = this.sortPolygonsReversed;\r\n\t\t\tthis.mapPolygons.sort((a, b) => {\r\n\t\t\t\tlet valA: number | string = \"\";\r\n\t\t\t\tlet valB: number | string = \"\";\r\n\t\t\t\tlet dirA: Ordering = -1;\r\n\t\t\t\tlet dirB: Ordering = 1;\r\n\r\n\t\t\t\tswitch (sortBy) {\r\n\t\t\t\t\tcase \"area\":\r\n\t\t\t\t\t\tvalA = a.boxArea;\r\n\t\t\t\t\t\tvalB = b.boxArea;\r\n\t\t\t\t\t\tdirA = -1;\r\n\t\t\t\t\t\tdirB = 1;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase \"name\":\r\n\t\t\t\t\t\tvalA = (a).dataItem.dataContext.name || \"\";\r\n\t\t\t\t\t\tvalB = (b).dataItem.dataContext.name || \"\";\r\n\t\t\t\t\t\tdirA = 1;\r\n\t\t\t\t\t\tdirB = -1;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase \"id\":\r\n\t\t\t\t\t\tvalA = (a).dataItem.dataContext.id || \"\";\r\n\t\t\t\t\t\tvalB = (b).dataItem.dataContext.id || \"\";\r\n\t\t\t\t\t\tdirA = 1;\r\n\t\t\t\t\t\tdirB = -1;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase \"latitude\":\r\n\t\t\t\t\t\tvalA = reversed ? a.south : a.north;\r\n\t\t\t\t\t\tvalB = reversed ? b.south : b.north;\r\n\t\t\t\t\t\tdirA = -1;\r\n\t\t\t\t\t\tdirB = 1;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase \"longitude\":\r\n\t\t\t\t\t\tvalA = reversed ? a.east : a.west;\r\n\t\t\t\t\t\tvalB = reversed ? b.east : b.west;\r\n\t\t\t\t\t\tdirA = 1;\r\n\t\t\t\t\t\tdirB = -1;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (valA < valB) {\r\n\t\t\t\t\treturn reversed ? dirB : dirA;\r\n\t\t\t\t}\r\n\t\t\t\tif (valA > valB) {\r\n\t\t\t\t\treturn reversed ? dirA : dirB;\r\n\t\t\t\t}\r\n\t\t\t\treturn 0;\r\n\t\t\t});\r\n\r\n\t\t\tthis.mapPolygons.each((mapPolygon, index) => {\r\n\t\t\t\tmapPolygon.validate();\r\n\t\t\t\t// makes small go first to avoid hover problems with IE\r\n\t\t\t\tif (!mapPolygon.zIndex && !mapPolygon.propertyFields.zIndex) {\r\n\t\t\t\t\tmapPolygon.zIndex = 1000000 - index;\r\n\t\t\t\t}\r\n\t\t\t})\r\n\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * List of polygon elements in the series.\r\n\t *\r\n\t * @return Polygon list\r\n\t */\r\n\tpublic get mapPolygons(): ListTemplate {\r\n\r\n\t\tif (!this._mapPolygons) {\r\n\t\t\tlet polygonTemplate: MapPolygon = new MapPolygon();\r\n\r\n\t\t\tlet mapPolygons: ListTemplate = new ListTemplate(polygonTemplate);\r\n\t\t\tthis._disposers.push(new ListDisposer(mapPolygons));\r\n\t\t\tthis._disposers.push(mapPolygons.template);\r\n\t\t\tmapPolygons.template.focusable = true;\r\n\t\t\tmapPolygons.events.on(\"inserted\", this.handleObjectAdded, this, false);\r\n\t\t\tthis._mapPolygons = mapPolygons;\r\n\t\t\tthis._mapObjects = mapPolygons;\r\n\t\t}\r\n\r\n\t\treturn this._mapPolygons;\r\n\t}\r\n\r\n\t/**\r\n\t * returns MapPolygon by id in geoJSON file\r\n\t * @param polygon id\r\n\t * @return {MapPolygon}\r\n\t */\r\n\tpublic getPolygonById(id: string): MapPolygon {\r\n\t\treturn $iter.find(this.mapPolygons.iterator(), (mapPolygon) => {\r\n\t\t\tlet dataContext: any = mapPolygon.dataItem.dataContext;\r\n\t\t\treturn dataContext.id == id;\r\n\t\t});\r\n\t}\r\n\r\n\t/**\r\n\t * Copies all properties from another instance of [[Series]].\r\n\t *\r\n\t * @param source Source series\r\n\t */\r\n\tpublic copyFrom(source: this) {\r\n\t\tthis.mapPolygons.template.copyFrom(source.mapPolygons.template);\r\n\t\tsuper.copyFrom(source);\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeatures(): { \"type\": \"Feature\", geometry: { type: \"MultiPolygon\", coordinates: Array>> } }[] {\r\n\r\n\t\tlet features: { \"type\": \"Feature\", geometry: { type: \"MultiPolygon\", coordinates: Array>> } }[] = [];\r\n\r\n\t\tthis.dataItems.each((dataItem) => {\r\n\t\t\tlet feature = dataItem.getFeature();\r\n\t\t\tif (feature) {\r\n\t\t\t\tfeatures.push(feature);\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\tthis.mapPolygons.each((mapPolygon) => {\r\n\t\t\tif (this.dataItems.indexOf(mapPolygon._dataItem) == -1) {\r\n\t\t\t\tlet feature = mapPolygon.getFeature();\r\n\t\t\t\tif (feature) {\r\n\t\t\t\t\tfeatures.push(feature);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t})\r\n\t\treturn features;\r\n\t}\r\n\r\n\t/**\r\n\t * How to order polygons in actual SVG document. Affects selection order\r\n\t * using TAB key.\r\n\t *\r\n\t * Available options: `\"area\"` (default), `\"name\"`, `\"longitude\"`,\r\n\t * `\"latitude\"`, `\"id\"`, and `\"none\"`.\r\n\t *\r\n\t * @default area\r\n\t * @since 4.9.36\r\n\t * @param value How to sort map polygons\r\n\t */\r\n\tpublic set sortPolygonsBy(value: \"area\" | \"name\" | \"longitude\" | \"latitude\" | \"id\" | \"none\") {\r\n\t\tif (this.setPropertyValue(\"sortPolygonsBy\", value)) {\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return How to sort map polygons\r\n\t */\r\n\tpublic get sortPolygonsBy(): \"area\" | \"name\" | \"longitude\" | \"latitude\" | \"id\" | \"none\" {\r\n\t\treturn this.getPropertyValue(\"sortPolygonsBy\");\r\n\t}\r\n\r\n\t/**\r\n\t * If `sortPolygonsBy` is set to something other than `\"none\"`, polygons\r\n\t * will be sorted by the given parameter, using natural sort direction.\r\n\t *\r\n\t * Setting `sortPolygonsReversed = true` will reverse this direction.\r\n\t *\r\n\t * @default false\r\n\t * @since 4.9.36\r\n\t * @param value Reverse polygon sort direction\r\n\t */\r\n\tpublic set sortPolygonsReversed(value: boolean) {\r\n\t\tif (this.setPropertyValue(\"sortPolygonsReversed\", value)) {\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Reverse polygon sort direction\r\n\t */\r\n\tpublic get sortPolygonsReversed(): boolean {\r\n\t\treturn this.getPropertyValue(\"sortPolygonsReversed\");\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapPolygonSeries\"] = MapPolygonSeries;\r\nregistry.registeredClasses[\"MapPolygonSeriesDataItem\"] = MapPolygonSeriesDataItem;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapPolygonSeries.ts","/**\r\n * This module contains funcitonality related to geographical projections\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { IGeoPoint } from \"../../../core/defs/IGeoPoint\";\r\n//import { IGeoRectangle } from \"../../../core/defs/IGeoRectangle\";\r\nimport { IPoint, IOrientationPoint } from \"../../../core/defs/IPoint\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as $math from \"../../../core/utils/Math\";\r\nimport * as d3geo from \"d3-geo\";\r\nimport { MapChart } from \"../../types/MapChart\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * This is a base class for a geographical projection.\r\n */\r\nexport class Projection {\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _d3Projection: d3geo.GeoProjection;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _d3Path: d3geo.GeoPath;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic chart: MapChart;\r\n\r\n\r\n\tconstructor() {\r\n\t\tthis.d3Projection = d3geo.geoEquirectangular();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * d3 projection\r\n\t */\r\n\tpublic set d3Projection(projection: d3geo.GeoProjection) {\r\n\t\tthis._d3Projection = projection;\r\n\t\tprojection.precision(0.1);\r\n\t\tthis._d3Path = d3geo.geoPath().projection(projection);\r\n\r\n\t\tif (this.chart) {\r\n\t\t\tthis.chart.invalidateProjection();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * d3 projection\r\n\t */\r\n\tpublic get d3Projection(): d3geo.GeoProjection {\r\n\t\treturn this._d3Projection;\r\n\t}\r\n\r\n\t/**\r\n\t * d3 path generator method\r\n\t * @ignore\r\n\t */\r\n\tpublic get d3Path(): d3geo.GeoPath {\r\n\t\treturn this._d3Path;\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic get scale(): number {\r\n\t\treturn this.d3Projection.scale() / 100;\r\n\t}\r\n\r\n\t/**\r\n\t * Converts a geographical point (lat/long) to a screen point (x/y)\r\n\t * @param geoPoint Geo point (lat/long)\r\n\t * @return Screen point (x/y)\r\n\t */\r\n\tpublic convert(geoPoint: IGeoPoint): IPoint {\r\n\t\t/*\r\n\t\tgeoPoint = $geo.normalizePoint(geoPoint);\r\n\t\tgeoPoint = this.rotate(geoPoint, this.deltaLongitude, this.deltaLatitude, this.deltaGama);\r\n\t\tlet pointInRadians: IPoint = this.project(geoPoint.longitude * $math.RADIANS, geoPoint.latitude * $math.RADIANS);\r\n\t\treturn {\r\n\t\t\tx: $math.round(pointInRadians.x * $math.DEGREES - this.centerPoint.x, 4) * this.scale,\r\n\t\t\ty: $math.round(-pointInRadians.y * $math.DEGREES - this.centerPoint.y, 4) * this.scale\r\n\t\t};*/\r\n\r\n\t\tlet p = this.d3Projection([geoPoint.longitude, geoPoint.latitude]);\r\n\t\tif (p) {\r\n\t\t\treturn { x: p[0], y: p[1] };\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Converts a screen point (x/y) to a geographical point (lat/long)\r\n\t * @param point Screen point (x/y)\r\n\t * @return Geo point (lat/long)\r\n\t */\r\n\tpublic invert(point: IPoint): IGeoPoint {\r\n\t\t/*\r\n\t\tlet pointInRadians: IGeoPoint = this.unproject((point.x / this.scale + this.centerPoint.x) * $math.RADIANS, (-point.y / this.scale - this.centerPoint.y) * $math.RADIANS);\r\n\r\n\t\tlet geoPoint = { longitude: pointInRadians.longitude * $math.DEGREES, latitude: pointInRadians.latitude * $math.DEGREES };\r\n\r\n\t\tgeoPoint = this.unrotate(geoPoint, this.deltaLongitude, this.deltaLatitude, this.deltaGama);\r\n\t\t*/\r\n\t\tlet p = this.d3Projection.invert([point.x, point.y]);\r\n\t\tif (p) {\r\n\t\t\treturn { longitude: p[0], latitude: p[1] };\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Returns X/Y coordinates.\r\n\t * Individual projections will override this method to apply their own\r\n\t * projection logic.\r\n\t * @deprecated\r\n\t * @param lambda [description]\r\n\t * @param phi [description]\r\n\t * @return X/Y coordinates\r\n\t * @todo Needs description\r\n\t */\r\n\tpublic project(lambda: number, phi: number): IPoint {\r\n\t\treturn this.convert({ longitude: lambda * $math.DEGREES, latitude: phi * $math.DEGREES });\r\n\t}\r\n\r\n\t/**\r\n\t * Returns geographical coordinates (lat/long).\r\n\t * Individual projections will override this method to apply their own\r\n\t * projection logic.\r\n\t * @deprecated\r\n\t * @param x X coordinate\r\n\t * @param y Y coordinate\r\n\t * @return Geographical point\r\n\t * @todo Needs description\r\n\t */\r\n\tpublic unproject(x: number, y: number): IGeoPoint {\r\n\t\treturn this.invert({ x: x, y: y });\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * @ignore\r\n\t * @deprecated\r\n\t */\r\n\tpublic rotate(geoPoint: IGeoPoint, deltaLongitude: number, deltaLatitude: number, deltaGamma?: number): IGeoPoint {\r\n\r\n\t\tlet deltaLambda = deltaLongitude * $math.RADIANS;\r\n\t\tlet deltaPhi = deltaLatitude * $math.RADIANS;\r\n\t\tdeltaGamma = deltaGamma * $math.RADIANS;\r\n\r\n\t\tlet lambda = geoPoint.longitude * $math.RADIANS + deltaLambda;\r\n\t\tlet phi = geoPoint.latitude * $math.RADIANS;\r\n\r\n\t\tlet cosDeltaPhi = Math.cos(deltaPhi);\r\n\t\tlet sinDeltaPhi = Math.sin(deltaPhi);\r\n\t\tlet cosDeltaGamma = Math.cos(deltaGamma);\r\n\t\tlet sinDeltaGamma = Math.sin(deltaGamma);\r\n\r\n\t\tlet cosPhi = Math.cos(phi);\r\n\r\n\t\tlet x = Math.cos(lambda) * cosPhi;\r\n\t\tlet y = Math.sin(lambda) * cosPhi;\r\n\t\tlet z = Math.sin(phi);\r\n\t\tlet k = z * cosDeltaPhi + x * sinDeltaPhi;\r\n\r\n\t\treturn { longitude: $math.DEGREES * Math.atan2(y * cosDeltaGamma - k * sinDeltaGamma, x * cosDeltaPhi - z * sinDeltaPhi), latitude: $math.DEGREES * Math.asin(k * cosDeltaGamma + y * sinDeltaGamma) };\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t * @deprecated\r\n\t */\r\n\tpublic unrotate(geoPoint: IGeoPoint, deltaLongitude: number, deltaLatitude: number, deltaGamma?: number): IGeoPoint {\r\n\r\n\t\tlet deltaLambda = deltaLongitude * $math.RADIANS;\r\n\t\tlet deltaPhi = deltaLatitude * $math.RADIANS;\r\n\t\tdeltaGamma = deltaGamma * $math.RADIANS;\r\n\r\n\t\tlet lambda = geoPoint.longitude * $math.RADIANS - deltaLambda;\r\n\t\tlet phi = geoPoint.latitude * $math.RADIANS;\r\n\r\n\t\tlet cosDeltaPhi = Math.cos(deltaPhi);\r\n\t\tlet sinDeltaPhi = Math.sin(deltaPhi);\r\n\t\tlet cosDeltaGamma = Math.cos(deltaGamma);\r\n\t\tlet sinDeltaGamma = Math.sin(deltaGamma);\r\n\r\n\t\tlet cosPhi = Math.cos(phi);\r\n\r\n\t\tlet x = Math.cos(lambda) * cosPhi;\r\n\t\tlet y = Math.sin(lambda) * cosPhi;\r\n\t\tlet z = Math.sin(phi);\r\n\t\tlet k = z * cosDeltaGamma - y * sinDeltaGamma;\r\n\r\n\t\treturn { longitude: $math.DEGREES * Math.atan2(y * cosDeltaGamma + z * sinDeltaGamma, x * cosDeltaPhi + k * sinDeltaPhi), latitude: $math.DEGREES * Math.asin(k * cosDeltaPhi - x * sinDeltaPhi) };\r\n\t}\r\n\r\n\r\n\t//@todo: move to some utils?\r\n\t//@todo: add credits to: https://www.movable-type.co.uk/scripts/latlong.html\r\n\tpublic intermediatePoint(pointA: IGeoPoint, pointB: IGeoPoint, position: number): IGeoPoint {\r\n\t\tlet p = d3geo.geoInterpolate([pointA.longitude, pointA.latitude], [pointB.longitude, pointB.latitude])(position);\r\n\t\treturn { longitude: p[0], latitude: p[1] };\r\n\t};\r\n\r\n\t// returns radians\r\n\tpublic multiDistance(multiGeoLine: Array>): number {\r\n\t\tlet distance = 0;\r\n\t\tfor (let s = 0; s < multiGeoLine.length; s++) {\r\n\t\t\tlet points: Array = multiGeoLine[s];\r\n\t\t\tif (points.length > 1) {\r\n\t\t\t\tfor (let p = 1; p < points.length; p++) {\r\n\t\t\t\t\tlet pointA = points[p - 1];\r\n\t\t\t\t\tlet pointB = points[p];\r\n\t\t\t\t\tdistance += this.distance(pointA, pointB);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn distance;\r\n\t}\r\n\r\n\t// returns radians\r\n\tpublic distance(pointA: IGeoPoint, pointB: IGeoPoint): number {\r\n\t\treturn d3geo.geoDistance([pointA.longitude, pointA.latitude], [pointB.longitude, pointB.latitude]);\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Converts relative position along the line (0-1) into pixel coordinates.\r\n\t *\r\n\t * @param position Position (0-1)\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic positionToPoint(multiGeoLine: Array>, position: number): IOrientationPoint {\r\n\r\n\t\tif (multiGeoLine) {\r\n\t\t\tlet intermediatePoint = this.positionToGeoPoint(multiGeoLine, position);\r\n\t\t\tlet intermediatePointA = this.positionToGeoPoint(multiGeoLine, position - 0.01);\r\n\t\t\tlet intermediatePointB = this.positionToGeoPoint(multiGeoLine, position + 0.01);\r\n\r\n\t\t\tif (intermediatePointA && intermediatePointB) {\r\n\r\n\t\t\t\tlet point = this.convert(intermediatePoint);\r\n\r\n\t\t\t\tlet pa = this.convert(intermediatePointA);\r\n\t\t\t\tlet pb = this.convert(intermediatePointB);\r\n\r\n\t\t\t\treturn { x: point.x, y: point.y, angle: $math.getAngle(pa, pb) };\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn { x: 0, y: 0, angle: 0 };\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Converts relative position along the line (0-1) into pixel coordinates.\r\n\t *\r\n\t * @param position Position (0-1)\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic positionToGeoPoint(multiGeoLine: Array>, position: number): IGeoPoint {\r\n\r\n\t\tif (multiGeoLine) {\r\n\t\t\tlet totalDistance: number = this.multiDistance(multiGeoLine);\r\n\t\t\tlet currentDistance: number = 0;\r\n\r\n\t\t\tlet distanceAB: number;\r\n\t\t\tlet positionA: number = 0;\r\n\t\t\tlet positionB: number = 0;\r\n\t\t\tlet pointA: IGeoPoint;\r\n\t\t\tlet pointB: IGeoPoint;\r\n\r\n\t\t\tfor (let s = 0; s < multiGeoLine.length; s++) {\r\n\t\t\t\tlet points: Array = multiGeoLine[s];\r\n\t\t\t\tif (points.length > 1) {\r\n\t\t\t\t\tfor (let p = 1; p < points.length; p++) {\r\n\t\t\t\t\t\tpointA = points[p - 1];\r\n\t\t\t\t\t\tpointB = points[p];\r\n\r\n\t\t\t\t\t\tpositionA = currentDistance / totalDistance;\r\n\t\t\t\t\t\tdistanceAB = this.distance(pointA, pointB);\r\n\t\t\t\t\t\tcurrentDistance += distanceAB;\r\n\t\t\t\t\t\tpositionB = currentDistance / totalDistance;\r\n\r\n\t\t\t\t\t\tif (positionA <= position && positionB > position) {\r\n\t\t\t\t\t\t\ts = multiGeoLine.length;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\telse if (points.length == 1) {\r\n\t\t\t\t\tpointA = points[0];\r\n\t\t\t\t\tpointB = points[0];\r\n\t\t\t\t\tpositionA = 0;\r\n\t\t\t\t\tpositionB = 1;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif (pointA && pointB) {\r\n\t\t\t\tlet positionAB: number = (position - positionA) / (positionB - positionA);\r\n\t\t\t\treturn this.intermediatePoint(pointA, pointB, positionAB);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn { longitude: 0, latitude: 0 };\r\n\t}\r\n}\r\n\r\n\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"Projection\"] = Projection;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/Projection.ts","/**\r\n * A module for the mini-map control.\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Container, IContainerProperties, IContainerAdapters, IContainerEvents } from \"../../core/Container\";\r\nimport { IRectangle } from \"../../core/defs/IRectangle\";\r\nimport { Sprite, ISpriteEvents, AMEvent } from \"../../core/Sprite\";\r\nimport { Rectangle } from \"../../core/elements/Rectangle\";\r\nimport { IPoint } from \"../../core/defs/IPoint\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { MapChart } from \"../types/MapChart\";\r\nimport { MapSeries } from \"./MapSeries\";\r\nimport { List, IListEvents } from \"../../core/utils/List\";\r\nimport { MutableValueDisposer, MultiDisposer } from \"../../core/utils/Disposer\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport { color } from \"../../core/utils/Color\";\r\nimport { InterfaceColorSet } from \"../../core/utils/InterfaceColorSet\";\r\nimport * as $utils from \"../../core/utils/Utils\";\r\nimport * as $type from \"../../core/utils/Type\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[SmallMap]].\r\n */\r\nexport interface ISmallMapProperties extends IContainerProperties { }\r\n\r\n/**\r\n * Defines events for [[SmallMap]].\r\n */\r\nexport interface ISmallMapEvents extends IContainerEvents { }\r\n\r\n/**\r\n * Defines adapters for [[SmallMap]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface ISmallMapAdapters extends IContainerAdapters, ISmallMapProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Creates a \"bird's eye\" view of the whole map.\r\n *\r\n * This control creates a mini-map with the whole of the map, highlighting\r\n * the area which is in the current viewport of the map map.\r\n *\r\n * @see {@link ISmallMapEvents} for a list of available events\r\n * @see {@link ISmallMapAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class SmallMap extends Container {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: ISmallMapProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: ISmallMapAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: ISmallMapEvents;\r\n\r\n\t/**\r\n\t * A target map.\r\n\t */\r\n\tprotected _chart: MutableValueDisposer = new MutableValueDisposer();\r\n\r\n\t/**\r\n\t * A container that holds the visual elements for the mini-map.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic seriesContainer: Container;\r\n\r\n\t/**\r\n\t * The rectangle element which highlights current viewport.\r\n\t */\r\n\tpublic rectangle: Rectangle;\r\n\r\n\t/**\r\n\t * A list of map series used to draw the mini-map.\r\n\t */\r\n\tprotected _series: List;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"SmallMap\";\r\n\r\n\t\t// Set defaults\r\n\t\tthis.align = \"left\";\r\n\t\tthis.valign = \"bottom\";\r\n\t\tthis.percentHeight = 20;\r\n\t\tthis.percentWidth = 20;\r\n\t\tthis.margin(5, 5, 5, 5);\r\n\r\n\t\tlet interfaceColors = new InterfaceColorSet();\r\n\r\n\t\t// Set background defailts\r\n\t\tthis.background.fillOpacity = 0.9;\r\n\t\tthis.background.fill = interfaceColors.getFor(\"background\");\r\n\r\n\t\t// Set up events\r\n\t\tthis.events.on(\"hit\", this.moveToPosition, this, false);\r\n\t\tthis.events.on(\"maxsizechanged\", this.updateMapSize, this, false);\r\n\r\n\t\t// Create a container\r\n\t\tthis.seriesContainer = this.createChild(Container);\r\n\t\tthis.seriesContainer.shouldClone = false;\r\n\r\n\t\t// Create an outline rectangle\r\n\t\tlet rectangle: Rectangle = this.createChild(Rectangle);\r\n\t\trectangle.shouldClone = false;\r\n\t\trectangle.stroke = interfaceColors.getFor(\"alternativeBackground\");\r\n\t\trectangle.strokeWidth = 1;\r\n\t\trectangle.strokeOpacity = 0.5;\r\n\t\trectangle.fill = color(); //\"none\";\r\n\t\trectangle.verticalCenter = \"middle\";\r\n\t\trectangle.horizontalCenter = \"middle\";\r\n\t\trectangle.isMeasured = false;\r\n\t\trectangle.visible = false;\t\t\r\n\r\n\t\tthis.rectangle = rectangle;\r\n\r\n\t\tthis._disposers.push(this._chart);\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * A list of map series used to draw the mini-map.\r\n\t *\r\n\t * @readonly\r\n\t * @return Series\r\n\t */\r\n\tpublic get series(): List {\r\n\t\tif (!this._series) {\r\n\t\t\tthis._series = new List();\r\n\t\t\tthis._series.events.on(\"inserted\", this.handleSeriesAdded, this, false);\r\n\t\t\tthis._series.events.on(\"removed\", this.handleSeriesRemoved, this, false);\r\n\t\t}\r\n\t\treturn this._series;\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Decorates a new series when they are pushed into a `series` list.\r\n\t *\r\n\t * @param event Event\r\n\t */\r\n\tprotected handleSeriesAdded(event: IListEvents[\"inserted\"]) {\r\n\t\tlet series: MapSeries = event.newValue;\r\n\t\tif (this.chart.series.contains(series)) {\r\n\t\t\tlet newSeries = series.clone();\r\n\t\t\tthis._series.removeValue(series);\r\n\t\t\tthis._series.push(newSeries);\r\n\t\t\tseries = newSeries;\r\n\r\n\t\t\tthis.chart.dataUsers.push(newSeries);\r\n\t\t}\r\n\t\tseries.chart = this.chart;\r\n\t\tseries.parent = this.seriesContainer;\r\n\t\tseries.interactionsEnabled = false;\r\n\t\tseries.events.on(\"inited\", this.updateMapSize, this, false);\r\n\t\tseries.hidden = false;\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Cleans up after series are removed from Scrollbar.\r\n\t *\r\n\t * @param event Event\r\n\t */\r\n\tprotected handleSeriesRemoved(event: IListEvents[\"removed\"]) {\r\n\t\t//let sourceSeries: MapSeries = event.oldValue;\r\n\t\tthis.invalidate();\r\n\t}\r\n\r\n\t/**\r\n\t * Moves main map pan position after click on the small map.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @param event Event\r\n\t */\r\n\tpublic moveToPosition(event: AMEvent[\"hit\"]) {\r\n\t\tlet rectPoint: IPoint = $utils.spritePointToSprite(event.spritePoint, this, this.seriesContainer);\r\n\t\tlet geoPoint: IGeoPoint = this.chart.seriesPointToGeo(rectPoint);\r\n\t\tthis.chart.zoomToGeoPoint(geoPoint, this.chart.zoomLevel, true);\r\n\t}\r\n\r\n\t/**\r\n\t * A chart/map that this control is meant for.\r\n\t *\r\n\t * @param chart Chart/map\r\n\t */\r\n\tpublic set chart(chart: MapChart) {\r\n\t\tif (this.chart != chart) {\r\n\t\t\tthis._chart.set(chart, new MultiDisposer([\r\n\t\t\t\t//chart.events.on(\"zoomlevelchanged\", this.updateRectangle, this, false),\r\n\t\t\t\tchart.events.on(\"mappositionchanged\", this.updateRectangle, this, false),\r\n\t\t\t\tchart.events.on(\"scaleratiochanged\", this.updateMapSize, this, false)\r\n\t\t\t]));\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Chart/map\r\n\t */\r\n\tpublic get chart(): MapChart {\r\n\t\treturn this._chart.get();\r\n\t}\r\n\r\n\t/**\r\n\t * Updates the viewport recangle as per current map zoom/pan position.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic updateRectangle(): void {\r\n\t\tlet chart: MapChart = this.chart;\r\n\t\tlet zoomLevel: number = chart.zoomLevel;\r\n\t\tlet rectangle: Rectangle = this.rectangle;\r\n\r\n\t\trectangle.width = this.pixelWidth / zoomLevel;\r\n\t\trectangle.height = this.pixelHeight / zoomLevel;\r\n\r\n\t\tlet scale: number = Math.min(this.percentWidth, this.percentHeight) / 100;\r\n\r\n\t\tlet seriesContainer: Container = chart.seriesContainer;\r\n\r\n\t\trectangle.x = Math.ceil(( - seriesContainer.pixelX) * scale / zoomLevel) + this.seriesContainer.pixelX;\r\n\t\trectangle.y = Math.ceil(( - seriesContainer.pixelY) * scale / zoomLevel) + this.seriesContainer.pixelY;\r\n\r\n\t\trectangle.validate();\r\n\t}\r\n\r\n\t/**\r\n\t * Update map size so that internal elements can redraw themselves after\r\n\t * the size of the small map changes.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic updateMapSize(): void {\r\n\t\tif (this.chart) {\r\n\t\t\tlet scale = this.chart.scaleRatio * Math.min(this.percentWidth, this.percentHeight) / 100;\r\n\t\t\tthis.seriesContainer.scale = scale;\r\n\r\n\t\t\tlet bbox: IRectangle = {\r\n\t\t\t\twidth: 0,\r\n\t\t\t\theight: 0,\r\n\t\t\t\tx: 0,\r\n\t\t\t\ty: 0\r\n\t\t\t};\r\n\r\n\t\t\ttry { // Add exception catching to tame FF\r\n\t\t\t\tbbox = this.seriesContainer.group.node.getBBox();\r\n\t\t\t} catch (err) { }\r\n\r\n\t\t\tif(bbox.width > 0){\r\n\t\t\t\tthis.rectangle.visible = true;\r\n\t\t\t}\r\n\r\n\t\t\tthis.seriesContainer.x = this.pixelWidth / 2 - bbox.x * scale - bbox.width / 2 * scale;\r\n\t\t\tthis.seriesContainer.y = this.pixelHeight / 2 - bbox.y * scale - bbox.height / 2 * scale;\r\n\r\n\t\t\tthis.updateRectangle();\r\n\t\t\tthis.afterDraw();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Update elements after drawing the small map.\r\n\t */\r\n\tprotected afterDraw(): void {\r\n\t\tsuper.afterDraw();\r\n\t\t//this.seriesContainer.moveTo({ x: this.pixelWidth / 2, y: this.pixelHeight / 2 });\r\n\t\tthis.rectangle.maskRectangle = { x: -1, y: -1, width: Math.ceil(this.pixelWidth + 2), height: Math.ceil(this.pixelHeight + 2) };\r\n\t}\r\n\r\n\t/**\r\n\t * Processes JSON-based config before it is applied to the object.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @param config Config\r\n\t */\r\n\tpublic processConfig(config?: { [index: string]: any }): void {\r\n\r\n\t\tif (config) {\r\n\r\n\t\t\t// Set up series\r\n\t\t\tif ($type.hasValue(config.series) && $type.isArray(config.series)) {\r\n\t\t\t\tfor (let i = 0, len = config.series.length; i < len; i++) {\r\n\t\t\t\t\tlet series = config.series[i];\r\n\t\t\t\t\tif ($type.hasValue(series) && $type.isString(series) && this.map.hasKey(series)) {\r\n\t\t\t\t\t\tconfig.series[i] = this.map.getKey(series);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\tsuper.processConfig(config);\r\n\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"SmallMap\"] = SmallMap;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/SmallMap.ts","/**\r\n * A collection of GeoJSON format-related utility functions.\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { IPoint } from \"../../core/defs/IPoint\";\r\nimport * as $math from \"../../core/utils/Math\";\r\nimport * as $array from \"../../core/utils/Array\";\r\n\r\n\r\n/**\r\n * Normalizes a geo-point.\r\n *\r\n * @ignore Exclude from docs\r\n * @param geoPoint Source geo-point\r\n * @return Normalized geo-point\r\n */\r\nexport function normalizePoint(geoPoint: IGeoPoint): IGeoPoint {\r\n\tlet longitude = wrapAngleTo180(geoPoint.longitude);\r\n\tlet latitude = Math.asin(Math.sin((geoPoint.latitude * $math.RADIANS))) * $math.DEGREES;\r\n\r\n\tlet latitude180 = wrapAngleTo180(geoPoint.latitude);\r\n\r\n\tif (Math.abs(latitude180) > 90) {\r\n\t\tlongitude = wrapAngleTo180(longitude + 180);\r\n\t}\r\n\r\n\tgeoPoint.longitude = longitude;\r\n\tgeoPoint.latitude = latitude;\r\n\r\n\treturn geoPoint;\r\n}\r\n\r\n/**\r\n * Normalizes all points of a geo-line.\r\n *\r\n * @ignore Exclude from docs\r\n * @param multiline Source geo-line\r\n * @return Normalized geo-line\r\n */\r\nexport function normalizeMultiline(multiline: Array>): Array> {\r\n\t$array.each(multiline, (segment) => {\r\n\t\t$array.each(segment, (point) => {\r\n\t\t\tnormalizePoint(point);\r\n\t\t});\r\n\t});\r\n\treturn multiline;\r\n}\r\n\r\n/**\r\n * [wrapAngleTo180 description]\r\n *\r\n * @todo Description\r\n * @ignore Exclude from docs\r\n * @param angle Angle\r\n * @return Angle\r\n */\r\nexport function wrapAngleTo180(angle: number): number {\r\n\tangle = angle % 360;\r\n\r\n\tif (angle > 180) {\r\n\t\tangle -= 360;\r\n\t}\r\n\tif (angle < -180) {\r\n\t\tangle += 360;\r\n\t}\r\n\r\n\treturn angle;\r\n}\r\n\r\n/**\r\n * Converts a geo point to a regular point object.\r\n *\r\n * @ignore Exclude from docs\r\n * @param geoPoint Source geo point\r\n * @return Point\r\n */\r\nexport function geoToPoint(geoPoint: IGeoPoint): IPoint {\r\n\treturn { x: geoPoint.longitude, y: geoPoint.latitude };\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/Geo.ts","/**\r\n * Map line module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Container, IContainerProperties, IContainerAdapters, IContainerEvents } from \"../../core/Container\";\r\nimport { MapLine } from \"./MapLine\";\r\nimport { IOrientationPoint } from \"../../core/defs/IPoint\";\r\nimport { registry } from \"../../core/Registry\";\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[MapLineObject]].\r\n */\r\nexport interface IMapLineObjectProperties extends IContainerProperties {\r\n\r\n\t/**\r\n\t * Sets object's relative position (0-1) within the line.\r\n\t *\r\n\t * `0` will place the object at the beginning of the line. `1` - at the end.\r\n\t *\r\n\t * Any intermediate number will place the object at some point within the\r\n\t * line.\r\n\t */\r\n\tposition?: number;\r\n\r\n\t/**\r\n\t * If set to `true`, the object will be automatically rotated to face the\r\n\t * direction of the line at the specific position.\r\n\t *\r\n\t * This allows creating images that has its \"front\" always facing the logical\r\n\t * direction of the line.\r\n\t *\r\n\t * @default false\r\n\t */\r\n\tadjustRotation?: boolean;\r\n\r\n}\r\n\r\n/**\r\n * Defines events for [[MapLineObject]].\r\n */\r\nexport interface IMapLineObjectEvents extends IContainerEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapLineObject]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapLineObjectAdapters extends IContainerAdapters, IMapLineObjectProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Draws a line on the map.\r\n *\r\n * @see {@link IMapLineObjectEvents} for a list of available events\r\n * @see {@link IMapLineObjectAdapters} for a list of available Adapters\r\n */\r\nexport class MapLineObject extends Container {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapLineObjectProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapLineObjectAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapLineObjectEvents;\r\n\r\n\t/**\r\n\t * A reference to the [[MapLine]] object this object is attached to.\r\n\t *\r\n\t * @todo Review if necessary (same as parent)\r\n\t */\r\n\tpublic mapLine: MapLine;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.adjustRotation = true;\r\n\t\tthis.className = \"MapLineObject\";\r\n\t\tthis.isMeasured = false;\r\n\t\tthis.layout = \"none\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates element's position.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validatePosition() {\r\n\r\n\t\tlet mapLine = this.mapLine;\r\n\r\n\t\tif (mapLine) {\r\n\r\n\t\t\tlet point: IOrientationPoint = mapLine.positionToPoint(this.position);\r\n\r\n\t\t\tthis.x = point.x;\r\n\t\t\tthis.y = point.y;\r\n\r\n\t\t\tif (this.adjustRotation) {\r\n\t\t\t\tthis.rotation = point.angle;\r\n\t\t\t}\r\n\r\n\t\t\tlet dataItem = this.mapLine.dataItem;\r\n\t\t\tif (dataItem) {\r\n\t\t\t\tlet series = this.mapLine.dataItem.component;\r\n\t\t\t\tthis.scale = 1 / series.scale;\r\n\t\t\t}\r\n\r\n\t\t\t// hide out of bounds\r\n\t\t\tif (mapLine.shortestDistance) {\r\n\r\n\t\t\t\tlet projection = this.mapLine.series.chart.projection;\r\n\r\n\t\t\t\tlet geoPoint = projection.positionToGeoPoint(mapLine.multiGeoLine, this.position);\r\n\r\n\t\t\t\tlet visible: any = projection.d3Path({ type: 'Point', coordinates: [geoPoint.longitude, geoPoint.latitude] });\r\n\r\n\t\t\t\tif (!visible) {\r\n\t\t\t\t\tthis.__disabled = true;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tthis.__disabled = false;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\tsuper.validatePosition();\r\n\t}\r\n\r\n\t/**\r\n\t * Sets object's relative position (0-1) within the line.\r\n\t *\r\n\t * `0` will place the object at the beginning of the line. `1` - at the end.\r\n\t *\r\n\t * Any intermediate number will place the object at some point within the\r\n\t * line.\r\n\t *\r\n\t * @param value Position within the line (0-1)\r\n\t */\r\n\tpublic set position(value: number) {\r\n\t\tthis.setPropertyValue(\"position\", value, false, true);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Position within the line\r\n\t */\r\n\tpublic get position(): number {\r\n\t\treturn this.getPropertyValue(\"position\");\r\n\t}\r\n\r\n\t/**\r\n\t * If set to `true`, the object will be automatically rotated to face the\r\n\t * direction of the line at the specific position.\r\n\t *\r\n\t * This allows creating images that has its \"front\" always facing the logical\r\n\t * direction of the line.\r\n\t *\r\n\t * @default false\r\n\t * @param value Auto-rotate\r\n\t */\r\n\tpublic set adjustRotation(value: boolean) {\r\n\t\tthis.setPropertyValue(\"adjustRotation\", value, false, true);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Auto-rotate\r\n\t */\r\n\tpublic get adjustRotation(): boolean {\r\n\t\treturn this.getPropertyValue(\"adjustRotation\");\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapLineObject\"] = MapLineObject;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapLineObject.ts","/**\r\n * Map image series module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapSeries, MapSeriesDataItem, GEOJSONGeometry, IMapSeriesProperties, IMapSeriesDataFields, IMapSeriesAdapters, IMapSeriesEvents } from \"./MapSeries\";\r\nimport { MapChart } from \"../types/MapChart\";\r\nimport { MapImage } from \"./MapImage\";\r\nimport { ListTemplate, ListDisposer } from \"../../core/utils/List\";\r\nimport { IMapImageDataObject } from \"../types/MapChart\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport * as $array from \"../../core/utils/Array\";\r\nimport * as $mapUtils from \"./MapUtils\";\r\nimport * as $utils from \"../../core/utils/Utils\";\r\nimport * as $iter from \"../../core/utils/Iterator\";\r\nimport * as $type from \"../../core/utils/Type\";\r\nimport { Disposer } from \"../../core/utils/Disposer\";\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[MapImageSeries]]\r\n * @see {@link DataItem}\r\n */\r\nexport class MapImageSeriesDataItem extends MapSeriesDataItem {\r\n\r\n\t/**\r\n\t * A [[MapImage]] element related to this data item.\r\n\t */\r\n\tprotected _mapImage: MapImage;\r\n\r\n\t/**\r\n\t * [_point description]\r\n\t *\r\n\t * @todo Description\r\n\t */\r\n\tprotected _point: [number, number];\r\n\r\n\t/**\r\n\t * Geographical coordinates image is placed at.\r\n\t */\r\n\tprotected _geoPoint: IGeoPoint;\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for\r\n\t */\r\n\tpublic _component!: MapImageSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapImageSeriesDataItem\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeature(): { \"type\": \"Feature\", geometry: { type: \"Point\", coordinates: [number, number] } } {\r\n\t\treturn { \"type\": \"Feature\", geometry: { type: \"Point\", coordinates: this.point } };\r\n\t}\r\n\r\n\t/**\r\n\t * A [[MapImage]] element related to this data item.\r\n\t *\r\n\t * @return Element\r\n\t */\r\n\tpublic get mapImage(): MapImage {\r\n\t\tif (!this._mapImage) {\r\n\t\t\tlet mapImage = this.component.mapImages.create();\r\n\t\t\tthis.addSprite(mapImage);\r\n\t\t\tthis._mapImage = mapImage;\r\n\t\t\tthis._disposers.push(mapImage);\r\n\t\t\tthis._disposers.push(new Disposer(() => {\r\n\t\t\t\tif (this.component) {\r\n\t\t\t\t\tthis.component.mapImages.removeValue(mapImage);\r\n\t\t\t\t}\r\n\t\t\t}));\r\n\t\t\tthis.mapObject = mapImage;\r\n\t\t}\r\n\t\treturn this._mapImage;\r\n\t}\r\n\r\n\t/**\r\n\t * [point description]\r\n\t *\r\n\t * @todo Description\r\n\t * @param point [description]\r\n\t */\r\n\tpublic set point(point: [number, number]) {\r\n\t\tthis._point = point;\r\n\t\tthis._geoPoint = $mapUtils.pointToGeo(point);\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @return [description]\r\n\t */\r\n\tpublic get point(): [number, number] {\r\n\t\treturn this._point;\r\n\t}\r\n\r\n\t/**\r\n\t * [point description]\r\n\t *\r\n\t * @todo Description\r\n\t * @param point [description]\r\n\t */\r\n\tpublic set multiPoint(multiPoint: [[number, number]]) {\r\n\t\tthis._point = multiPoint[0];\r\n\t\tthis._geoPoint = $mapUtils.pointToGeo(this._point);\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @return [description]\r\n\t */\r\n\tpublic get multiPoint(): [[number, number]] {\r\n\t\treturn [this._point];\r\n\t}\t\r\n\r\n\t/**\r\n\t * Geographical coordinates (lat/long) image is placed at.\r\n\t *\r\n\t * @param geoPoint Image coordinates\r\n\t */\r\n\tpublic set geoPoint(geoPoint: IGeoPoint) {\r\n\t\tthis._geoPoint = geoPoint;\r\n\t\tthis.point = [geoPoint.longitude, geoPoint.latitude];\r\n\t}\r\n\r\n\t/**\r\n\t * @return Image coordinates\r\n\t */\r\n\tpublic get geoPoint(): IGeoPoint {\r\n\t\treturn this._geoPoint;\r\n\t}\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines data fields for [[MapImageSeries]].\r\n */\r\nexport interface IMapImageSeriesDataFields extends IMapSeriesDataFields {\r\n\r\n\t/**\r\n\t * Field name that holds image point data in pixels.\r\n\t */\r\n\tpoint?: string;\r\n\r\n\t/**\r\n\t * Field name that holds multi-image point data in pixels.\r\n\t */\r\n\tmultiPoint?: string;\r\n\r\n\t/**\r\n\t * Field name that holds image point data in Geo coordinates.\r\n\t */\r\n\tgeoPoint?: string;\r\n\r\n\t/**\r\n\t * Field name that holds multi-image point data in Geo coordinates.\r\n\t */\r\n\tmultiGeoPoint?: string;\r\n\r\n}\r\n\r\n/**\r\n * Defines properties for [[MapImageSeries]].\r\n */\r\nexport interface IMapImageSeriesProperties extends IMapSeriesProperties { }\r\n\r\n/**\r\n * Defines events for [[MapImageSeries]].\r\n */\r\nexport interface IMapImageSeriesEvents extends IMapSeriesEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapImageSeries]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapImageSeriesAdapters extends IMapSeriesAdapters, IMapImageSeriesProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * A series of map image (marker) elements.\r\n *\r\n * @see {@link IMapImageSeriesEvents} for a list of available Events\r\n * @see {@link IMapImageSeriesAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class MapImageSeries extends MapSeries {\r\n\r\n\t/**\r\n\t * Defines available data fields.\r\n\t */\r\n\tpublic _dataFields: IMapImageSeriesDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapImageSeriesProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapImageSeriesAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapImageSeriesEvents;\r\n\r\n\t/**\r\n\t * Defines the type of data item.\r\n\t */\r\n\tpublic _dataItem: MapImageSeriesDataItem;\r\n\r\n\t/**\r\n\t * A related chart/map object, this image is drawn on.\r\n\t */\r\n\tpublic chart: MapChart;\r\n\r\n\t/**\r\n\t * A list of map images in the series.\r\n\t */\r\n\tprotected _mapImages: ListTemplate;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapImageSeries\";\r\n\r\n\t\t// Set data fields\r\n\t\tthis.dataFields.multiPoint = \"multiPoint\";\r\n\t\tthis.dataFields.point = \"point\";\r\n\r\n\t\tthis.dataFields.geoPoint = \"geoPoint\";\r\n\t\tthis.dataFields.multiGeoPoint = \"multiGeoPoint\";\r\n\r\n\t\tthis.ignoreBounds = true;\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new/empty DataItem of the type appropriate for this object.\r\n\t *\r\n\t * @see {@link DataItem}\r\n\t * @return Data Item\r\n\t */\r\n\tprotected createDataItem(): this[\"_dataItem\"] {\r\n\t\treturn new MapImageSeriesDataItem();\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates the data of the sries, effectively forcing it to redraw\r\n\t * all of its elements.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validateData(): void {\r\n\t\tif (this.data.length > 0 && this._parseDataFrom == 0) {\r\n\t\t\tthis.mapImages.clear();\r\n\t\t}\r\n\r\n\t\t// process geoJSON and created map objects\r\n\t\tif (this.useGeodata) {\r\n\t\t\tif (this.useGeodata || this.geodata) {\r\n\t\t\t\tlet geoJSON: any = this.chart.geodata;\r\n\r\n\t\t\t\tlet features: any[];\r\n\r\n\t\t\t\tif (geoJSON.type == \"FeatureCollection\") {\r\n\t\t\t\t\tfeatures = geoJSON.features;\r\n\t\t\t\t}\r\n\t\t\t\telse if (geoJSON.type == \"Feature\") {\r\n\t\t\t\t\tfeatures = [geoJSON];\r\n\t\t\t\t}\r\n\t\t\t\telse if ([\"Point\", \"LineString\", \"Polygon\", \"MultiPoint\", \"MultiLineString\", \"MultiPolygon\"].indexOf(geoJSON.type) != -1) {\r\n\t\t\t\t\tfeatures = [{ geometry: geoJSON }];\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tconsole.log(\"nothing found in geoJSON\");\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (features) {\r\n\t\t\t\t\tfor (let i = 0, len = features.length; i < len; i++) {\r\n\r\n\t\t\t\t\t\tlet feature: any = features[i];\r\n\t\t\t\t\t\tlet geometry: any = feature.geometry;\r\n\t\t\t\t\t\tif (geometry) {\r\n\t\t\t\t\t\t\tlet type: GEOJSONGeometry = geometry.type;\r\n\t\t\t\t\t\t\tlet id: string = feature.id;\r\n\t\t\t\t\t\t\tif (type == \"Point\" || type == \"MultiPoint\") { // todo: we don't support multipoints at the moment actually\r\n\r\n\t\t\t\t\t\t\t\tif (!this.checkInclude(this.include, this.exclude, id)) {\r\n\t\t\t\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tlet coordinates: any[] = geometry.coordinates;\r\n\r\n\t\t\t\t\t\t\t\t// make the same as MultiPoint\r\n\t\t\t\t\t\t\t\tif (type == \"Point\") {\r\n\t\t\t\t\t\t\t\t\tcoordinates = [coordinates];\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tlet dataObject: IMapImageDataObject = $array.find(this.data, (value, i) => {\r\n\t\t\t\t\t\t\t\t\treturn value.id == id;\r\n\t\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\t\tif (!dataObject) {\r\n\t\t\t\t\t\t\t\t\tdataObject = { multiPoint: coordinates, id: id, madeFromGeoData:true };\r\n\t\t\t\t\t\t\t\t\tthis.data.push(dataObject);\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t\t\tif (!dataObject.multiPoint) {\r\n\t\t\t\t\t\t\t\t\t\tdataObject.multiPoint = coordinates;\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\t// copy properties data to datacontext\r\n\t\t\t\t\t\t\t\t$utils.softCopyProperties(feature.properties, dataObject);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tsuper.validateData();\r\n\r\n\t\t// important! this should go after super.validateData\r\n\t\t// if data is parsed in chunks, images list is corrupted, fix it here\r\n\r\n\t\t$iter.each(this.dataItems.iterator(), (dataItem) => {\r\n\t\t\tlet mapImage = dataItem.mapImage;\r\n\t\t\tif (!mapImage.isDisposed()) {\r\n\t\t\t\tthis.mapImages.moveValue(mapImage);\r\n\t\t\t\tif ($type.isNumber(mapImage.latitude) && $type.isNumber(mapImage.latitude)) {\r\n\t\t\t\t\tdataItem.geoPoint = { latitude: mapImage.latitude, longitude: mapImage.longitude }\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\t}\r\n\r\n\t/**\r\n\t * A list of map images in the series.\r\n\t *\r\n\t * @return Map images\r\n\t */\r\n\tpublic get mapImages(): ListTemplate {\r\n\r\n\t\tif (!this._mapImages) {\r\n\t\t\tlet template: MapImage = new MapImage();\r\n\t\t\tlet mapImages = new ListTemplate(template);\r\n\t\t\tthis._disposers.push(new ListDisposer(mapImages));\r\n\t\t\tthis._disposers.push(mapImages.template);\r\n\t\t\tmapImages.template.focusable = true;\r\n\t\t\tmapImages.events.on(\"inserted\", this.handleObjectAdded, this, false);\r\n\t\t\tthis._mapImages = mapImages;\r\n\t\t\tthis._mapObjects = mapImages;\r\n\t\t}\r\n\r\n\t\treturn this._mapImages;\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates data element, effectively triggering its redrawal.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @param dataItem Data item\r\n\t */\r\n\tpublic validateDataElement(dataItem: this[\"_dataItem\"]) {\r\n\t\tsuper.validateDataElement(dataItem);\r\n\t\tdataItem.mapImage.invalidate();\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates the series\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validate() {\r\n\t\tsuper.validate();\r\n\t\t$iter.each(this.mapImages.iterator(), (mapImage) => {\r\n\t\t\tmapImage.validatePosition();\r\n\t\t})\r\n\t}\r\n\r\n\t/**\r\n\t * Copies all properties from another instance of [[Series]].\r\n\t *\r\n\t * @param source Source series\r\n\t */\r\n\tpublic copyFrom(source: this) {\r\n\t\tthis.mapImages.template.copyFrom(source.mapImages.template);\r\n\t\tsuper.copyFrom(source);\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeatures(): Array<{ \"type\": \"Feature\", geometry: { type: \"Point\", coordinates: [number, number] } }> {\r\n\t\tlet features: Array<{ \"type\": \"Feature\", geometry: { type: \"Point\", coordinates: [number, number] } }> = [];\r\n\r\n\t\tthis.dataItems.each((dataItem) => {\r\n\t\t\tlet feature = dataItem.getFeature();\r\n\t\t\tif (feature) {\r\n\t\t\t\tfeatures.push(feature);\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\tthis.mapImages.each((mapImage)=>{\r\n\t\t\tif (this.dataItems.indexOf(mapImage._dataItem) == -1) {\r\n\t\t\t\tlet feature = mapImage.getFeature();\r\n\t\t\t\tif (feature) {\r\n\t\t\t\t\tfeatures.push(feature);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t})\r\n\t\treturn features;\r\n\t}\r\n\r\n\t/**\r\n\t * returns MapImage by id\r\n\t * @param image id\r\n\t * @return {MapImage}\r\n\t */\r\n\tpublic getImageById(id: string): MapImage {\r\n\t\treturn $iter.find(this.mapImages.iterator(), (mapImage) => {\r\n\t\t\tlet dataContext: any = mapImage.dataItem.dataContext;\r\n\t\t\tif(mapImage.id == id || (dataContext && dataContext.id == id)){\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t});\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapImageSeries\"] = MapImageSeries;\r\nregistry.registeredClasses[\"MapImageSeriesDataItem\"] = MapImageSeriesDataItem;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapImageSeries.ts","/**\r\n * Map line module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapObject, IMapObjectProperties, IMapObjectAdapters, IMapObjectEvents } from \"./MapObject\";\r\nimport { MapLineObject } from \"./MapLineObject\";\r\nimport { MapLineSeriesDataItem, MapLineSeries } from \"./MapLineSeries\";\r\nimport { MapChart } from \"../types/MapChart\";\r\nimport { MapImage } from \"./MapImage\";\r\nimport { MapImageSeries } from \"./MapImageSeries\";\r\nimport { IOrientationPoint } from \"../../core/defs/IPoint\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { Triangle } from \"../../core/elements/Triangle\";\r\nimport { ListTemplate, IListEvents, ListDisposer } from \"../../core/utils/List\";\r\nimport { Polyline } from \"../../core/elements/Polyline\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport { color } from \"../../core/utils/Color\";\r\nimport { InterfaceColorSet } from \"../../core/utils/InterfaceColorSet\";\r\nimport { percent, Percent } from \"../../core/utils/Percent\";\r\nimport * as $type from \"../../core/utils/Type\";\r\nimport * as $iter from \"../../core/utils/Iterator\";\r\nimport { IDisposer } from \"../../core/utils/Disposer\";\r\nimport * as $geo from \"./Geo\";\r\nimport * as $mapUtils from \"./MapUtils\";\r\nimport { IPoint } from \"../../core/defs/IPoint\";\r\n\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[MapLine]].\r\n */\r\nexport interface IMapLineProperties extends IMapObjectProperties {\r\n\r\n\t/**\r\n\t * Lat/long coordinates of all line ends and intermediate elbows.\r\n\t */\r\n\tmultiGeoLine?: Array>;\r\n\r\n\t/**\r\n\t * Lat/long coordinates of all line ends and intermediate elbows.\r\n\t */\r\n\tmultiLine?: Array>;\r\n\r\n\t/**\r\n\t * If `true` it line will be arched in the way to simulate shortest path\r\n\t * over curvature of Earth's surface, based on currently used on projection.\r\n\t */\r\n\tshortestDistance?: boolean;\r\n\r\n\t/**\r\n\t * Instead of setting longitudes/latitudes you can set an array of images which will be connected by the line\r\n\t */\r\n\timagesToConnect?: MapImage[];\r\n\r\n\t/**\r\n\t * When line is plotted, if its `shortestDistance` is set to `true` it is\r\n\t * bent according to the used projection, to depict the shortest distance how\r\n\t * it would go on the actual land.\r\n\t *\r\n\t * `precision` introduces a setting which can control when such bending\r\n\t * occurs.\r\n\t *\r\n\t * If the distance (in degrees) between line start and end points\r\n\t * is less than `precision`, no bending will take place and the line will be\r\n\t * straight.\r\n\t *\r\n\t * Set to large number (e.g. 10000) for perfectly straight line.\r\n\t *\r\n\t * @since 4.9.1\r\n\t * @default 0.1\r\n\t */\r\n\tprecision?: number;\r\n\r\n}\r\n\r\n/**\r\n * Defines events for [[MapLine]].\r\n */\r\nexport interface IMapLineEvents extends IMapObjectEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapLine]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapLineAdapters extends IMapObjectAdapters, IMapLineProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Used to draw a line on the map.\r\n *\r\n * @see {@link IMapLineEvents} for a list of available events\r\n * @see {@link IMapLineAdapters} for a list of available Adapters\r\n */\r\nexport class MapLine extends MapObject {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapLineProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapLineAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapLineEvents;\r\n\r\n\t/**\r\n\t * A line visual element.\r\n\t */\r\n\tpublic line: Polyline;\r\n\r\n\t/**\r\n\t * A list of actual line objects.\r\n\t */\r\n\tprotected _lineObjects: ListTemplate;\r\n\r\n\t/**\r\n\t * A reference to arrow object.\r\n\t */\r\n\tprotected _arrow: MapLineObject;\r\n\r\n\t/**\r\n\t * Related data item.\r\n\t */\r\n\tpublic _dataItem: MapLineSeriesDataItem;\r\n\r\n\t/**\r\n\t * A map series this object belongs to.\r\n\t */\r\n\tpublic series: MapLineSeries;\r\n\r\n\t/**\r\n\t * Instead of setting longitudes/latitudes you can set an array of images\r\n\t * which will be connected by the line.\r\n\t */\r\n\tprotected _imagesToConnect: MapImage[];\r\n\r\n\t/**\r\n\t * A list of event disposers for images.\r\n\t */\r\n\tprotected _imageListeners: { [index: string]: IDisposer } = {};\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapLine\";\r\n\r\n\t\tthis.createLine();\r\n\t\tthis.line.stroke = color();\r\n\t\tthis.line.parent = this;\r\n\t\tthis.strokeOpacity = 1;\r\n\t\tthis.setPropertyValue(\"precision\", 0.1);\r\n\r\n\t\tlet interfaceColors = new InterfaceColorSet();\r\n\r\n\t\tthis.stroke = interfaceColors.getFor(\"grid\");\r\n\t\tthis.shortestDistance = true;\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected createLine() {\r\n\t\tthis.line = new Polyline();\r\n\t}\r\n\r\n\t/**\r\n\t * Converts a position within the line (0-1) to a physical point\r\n\t * coordinates.\r\n\t *\r\n\t * 0 indicates start of the line, 0.5 - middle, while 1 indicates the end.\r\n\t *\r\n\t * @param position Position (0-1)\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic positionToPoint(position: number): IOrientationPoint {\r\n\t\tif (this.shortestDistance) {\r\n\t\t\treturn this.series.chart.projection.positionToPoint(this.multiGeoLine, position);\r\n\t\t}\r\n\t\telse {\r\n\t\t\tif (this.line) {\r\n\t\t\t\treturn this.line.positionToPoint(position);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn { x: 0, y: 0, angle: 0 };\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-segment line. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * // Segment 1\r\n\t * [\r\n\t * { longitude: 3.121, latitude: 0.58 },\r\n\t * { longitude: -5.199, latitude: 21.223 }\r\n\t * ],\r\n\t *\r\n\t * // Segment 2\r\n\t * [\r\n\t * { longitude: -5.199, latitude: 21.223 },\r\n\t * { longitude: -12.9, latitude: 25.85 }\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @see {@link https://tools.ietf.org/html/rfc7946#section-3.1.5} GeoJSON MultiLineString reference\r\n\t * @param multiGeoLine Coordinates\r\n\t */\r\n\tpublic set multiGeoLine(multiGeoLine: Array>) {\r\n\t\tif (multiGeoLine && multiGeoLine.length > 0) {\r\n\t\t\tthis.setPropertyValue(\"multiGeoLine\", $geo.normalizeMultiline(multiGeoLine), true);\r\n\r\n\t\t\tlet multiLine: Array> = $mapUtils.multiGeoLineToMultiLine(multiGeoLine);\r\n\r\n\t\t\tthis.setPropertyValue(\"multiLine\", multiLine);\r\n\r\n\t\t\tthis.updateExtremes();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get multiGeoLine(): Array> {\r\n\t\tlet multiGeoLine = this.getPropertyValue(\"multiGeoLine\");\r\n\t\tif (!multiGeoLine && this.dataItem && this.dataItem.multiGeoLine) {\r\n\t\t\tmultiGeoLine = this.dataItem.multiGeoLine;\r\n\t\t}\r\n\r\n\t\treturn multiGeoLine;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-segment line. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * // Segment 1\r\n\t * [\r\n\t * [ 100, 150 ],\r\n\t * [ 120, 200 ]\r\n\t * ],\r\n\t *\r\n\t * // Segment 2\r\n\t * [\r\n\t * [ 120, 200 ],\r\n\t * [ 150, 100 ]\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @param multiLine Coordinates\r\n\t */\r\n\tpublic set multiLine(multiLine: Array>) {\r\n\t\tthis.setPropertyValue(\"multiLine\", multiLine);\r\n\t\tthis.multiGeoLine = $mapUtils.multiLineToGeo(multiLine);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get multiLine(): Array> {\r\n\r\n\t\tlet multiLine = this.getPropertyValue(\"multiLine\");\r\n\t\tif (!multiLine && this.dataItem && this.dataItem.multiLine) {\r\n\t\t\tmultiLine = this.dataItem.multiLine;\r\n\t\t}\r\n\r\n\t\treturn multiLine;\r\n\t}\r\n\r\n\t/**\r\n\t * Instead of setting longitudes/latitudes you can set an array of images\r\n\t * which will be connected by the line.\r\n\t *\r\n\t * Parameter is an array that can hold string `id`'s to of the images, or\r\n\t * references to actual [[MapImage]] objects.\r\n\t *\r\n\t * @param images Images\r\n\t */\r\n\tpublic set imagesToConnect(images: MapImage[] | string[]) {\r\n\t\tthis.setPropertyValue(\"imagesToConnect\", images, true);\r\n\t\tthis.handleImagesToConnect();\r\n\r\n\t\tif (this.series) {\r\n\t\t\tlet chart = this.series.chart;\r\n\t\t\tif (chart) {\r\n\t\t\t\tchart.series.each((series) => {\r\n\t\t\t\t\tif (series instanceof MapImageSeries) {\r\n\t\t\t\t\t\tif (!series.isReady()) {\r\n\t\t\t\t\t\t\tthis._disposers.push(series.events.on(\"ready\", this.handleImagesToConnect, this, false));\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t})\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return {MapImages[]}\r\n\t */\r\n\tpublic get imagesToConnect(): MapImage[] | string[] {\r\n\t\treturn this.getPropertyValue(\"imagesToConnect\");\r\n\t}\r\n\r\n\tprotected handleImagesToConnect() {\r\n\t\tif (this.imagesToConnect) {\r\n\t\t\tlet segment: Array = [];\r\n\t\t\tlet multiGeoLine = [segment];\r\n\r\n\t\t\tfor (let image of this.imagesToConnect) {\r\n\t\t\t\tif ($type.isString(image)) {\r\n\t\t\t\t\tlet chart = this.series.chart;\r\n\t\t\t\t\tif (chart) {\r\n\t\t\t\t\t\tchart.series.each((series) => {\r\n\t\t\t\t\t\t\tif (series instanceof MapImageSeries) {\r\n\t\t\t\t\t\t\t\tlet img = series.getImageById(image)\r\n\t\t\t\t\t\t\t\tif (img) {\r\n\t\t\t\t\t\t\t\t\timage = img;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (image instanceof MapImage) {\r\n\r\n\t\t\t\t\tsegment.push({ longitude: (image).longitude, latitude: (image).latitude });\r\n\r\n\t\t\t\t\tif (!this._imageListeners[image.uid]) {\r\n\t\t\t\t\t\tlet disposer = image.events.on(\"propertychanged\", (event) => {\r\n\t\t\t\t\t\t\tif (event.property == \"longitude\" || event.property == \"latitude\") {\r\n\t\t\t\t\t\t\t\tthis.handleImagesToConnect();\r\n\t\t\t\t\t\t\t\tthis.invalidate();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}, this, false);\r\n\t\t\t\t\t\tthis._imageListeners[image.uid] = disposer;\r\n\t\t\t\t\t\tthis._disposers.push(disposer);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tthis.multiGeoLine = multiGeoLine;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates the line, effectively forcing it to redraw.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validate(): void {\r\n\t\tlet chart: MapChart = this.series.chart;\r\n\r\n\t\tif (this.multiLine) {\r\n\r\n\t\t\tif (!this.shortestDistance) {\r\n\r\n\t\t\t\tlet convertedPoints: Array> = [];\r\n\r\n\t\t\t\tfor (let i = 0, len = this.multiLine.length; i < len; i++) {\r\n\r\n\t\t\t\t\tlet segment: Array<[number, number]> = this.multiLine[i];\r\n\r\n\t\t\t\t\tlet convertedSegmentPoints: Array = [];\r\n\r\n\t\t\t\t\tfor (let s = 0, slen = segment.length; s < slen; s++) {\r\n\t\t\t\t\t\tlet geoPoint: [number, number] = segment[s];\r\n\t\t\t\t\t\tlet point: IPoint = this.series.chart.projection.convert({ longitude: geoPoint[0], latitude: geoPoint[1] });\r\n\t\t\t\t\t\tconvertedSegmentPoints.push(point);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tconvertedPoints.push(convertedSegmentPoints);\r\n\t\t\t\t}\r\n\t\t\t\tthis.line.segments = convertedPoints;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tchart.projection.d3Projection.precision(this.precision);\r\n\t\t\t\tthis.line.path = chart.projection.d3Path(this.getFeature());\r\n\t\t\t}\r\n\r\n\t\t\tif (this._arrow) {\r\n\t\t\t\tthis._arrow.validatePosition();\r\n\t\t\t}\r\n\r\n\t\t\t$iter.each(this.lineObjects.iterator(), (x) => {\r\n\t\t\t\tx.validatePosition();\r\n\t\t\t});\r\n\r\n\t\t\tthis.handleGlobalScale();\r\n\t\t}\r\n\t\telse if (this.imagesToConnect) {\r\n\t\t\tthis.handleImagesToConnect();\r\n\t\t}\r\n\r\n\r\n\t\tsuper.validate();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeature(): { \"type\": \"Feature\", geometry: { type: \"MultiLineString\", coordinates: Array> } } {\r\n\t\tif (this.multiLine && this.multiLine.length > 0 && this.multiLine[0] && this.multiLine[0].length > 0) {\r\n\t\t\treturn { \"type\": \"Feature\", geometry: { type: \"MultiLineString\", coordinates: this.multiLine } };\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic measureElement(): void {\r\n\t\t// Overriding, just to avoid extra measure\r\n\t}\r\n\r\n\t/**\r\n\t * The line should take the shortest path over the globe.\r\n\t *\r\n\t * Enabling this will make the line look differently in different\r\n\t * projections. Only `MapLine` supports this setting, `MapArc` and\r\n\t * `MapSplice` don't.\r\n\t *\r\n\t * @default true\r\n\t * @param value Real path?\r\n\t */\r\n\tpublic set shortestDistance(value: boolean) {\r\n\t\tthis.setPropertyValue(\"shortestDistance\", value, true);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Real path?\r\n\t */\r\n\tpublic get shortestDistance(): boolean {\r\n\t\treturn this.getPropertyValue(\"shortestDistance\");\r\n\t}\r\n\r\n\t/**\r\n\t * List of separate line objects the line consists of.\r\n\t *\r\n\t * @readonly\r\n\t * @return List of line objects\r\n\t */\r\n\tpublic get lineObjects(): ListTemplate {\r\n\t\tif (!this._lineObjects) {\r\n\t\t\tthis._lineObjects = new ListTemplate(new MapLineObject());\r\n\t\t\tthis._lineObjects.events.on(\"inserted\", this.handleLineObjectAdded, this, false);\r\n\t\t\tthis._disposers.push(new ListDisposer(this._lineObjects));\r\n\t\t\tthis._disposers.push(this._lineObjects.template);\r\n\t\t}\r\n\r\n\t\treturn this._lineObjects;\r\n\t}\r\n\r\n\t/**\r\n\t * Decorate a [[LineObject]] when it is added to the line.\r\n\t *\r\n\t * @param event Event\r\n\t */\r\n\tprotected handleLineObjectAdded(event: IListEvents[\"inserted\"]) {\r\n\t\tlet mapLineObject: MapLineObject = event.newValue;\r\n\t\tmapLineObject.mapLine = this;\r\n\t\tmapLineObject.shouldClone = false;\r\n\t\tmapLineObject.parent = this;\r\n\t}\r\n\r\n\t/**\r\n\t * A [[MapLineObject]] to use as an option arrowhead on the line.\r\n\t *\r\n\t * Just accessing this property will create a default arrowhead on the line\r\n\t * automatically.\r\n\t *\r\n\t * @param arrow Arrow element\r\n\t */\r\n\tpublic set arrow(arrow: MapLineObject) {\r\n\t\tthis._arrow = arrow;\r\n\t\tarrow.mapLine = this;\r\n\t\tarrow.parent = this;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Arrow element\r\n\t */\r\n\tpublic get arrow(): MapLineObject {\r\n\t\tif (!this._arrow) {\r\n\t\t\tlet arrow: MapLineObject = this.createChild(MapLineObject);\r\n\t\t\tarrow.shouldClone = false;\r\n\t\t\tarrow.width = 8;\r\n\t\t\tarrow.height = 10;\r\n\t\t\tarrow.mapLine = this;\r\n\t\t\tarrow.position = 0.5;\r\n\r\n\t\t\tlet triangle = arrow.createChild(Triangle);\r\n\t\t\t//triangle.shouldClone = false;\r\n\t\t\ttriangle.fillOpacity = 1;\r\n\t\t\ttriangle.width = percent(100);\r\n\t\t\ttriangle.height = percent(100);\r\n\t\t\ttriangle.rotation = 90;\r\n\t\t\ttriangle.horizontalCenter = \"middle\";\r\n\t\t\ttriangle.verticalCenter = \"middle\";\r\n\t\t\tthis._arrow = arrow;\r\n\t\t}\r\n\t\treturn this._arrow;\r\n\t}\r\n\r\n\t/**\r\n\t * Copies line properties and other attributes, like arrow, from another\r\n\t * instance of [[MapLine]].\r\n\t *\r\n\t * @param source Source map line\r\n\t */\r\n\tpublic copyFrom(source: this): void {\r\n\t\tsuper.copyFrom(source);\r\n\t\tthis.line.copyFrom(source.line);\r\n\t\tthis.lineObjects.copyFrom(source.lineObjects);\r\n\t\tif (source._arrow) {\r\n\t\t\tthis.arrow = source.arrow.clone();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Latitude of the line center.\r\n\t *\r\n\t * @readonly\r\n\t * @return Latitude\r\n\t */\r\n\tpublic get latitude(): number {\r\n\t\treturn this.north + (this.south - this.north) / 2;\r\n\t}\r\n\r\n\t/**\r\n\t * Longitude of the line center.\r\n\t *\r\n\t * @readonly\r\n\t * @return Latitude\r\n\t */\r\n\tpublic get longitude(): number {\r\n\t\treturn this.east + (this.west - this.east) / 2;\r\n\t}\r\n\r\n\t/**\r\n\t * X coordinate for the slice tooltip.\r\n\t *\r\n\t * @ignore\r\n\t * @return X\r\n\t */\r\n\tpublic getTooltipX(): number {\r\n\t\tlet x = this.getPropertyValue(\"tooltipX\");\r\n\t\tif (!(x instanceof Percent)) {\r\n\t\t\tx = percent(50);\r\n\t\t}\r\n\t\tif (x instanceof Percent) {\r\n\t\t\treturn this.positionToPoint(x.value).x;\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Y coordinate for the slice tooltip.\r\n\t *\r\n\t * @ignore\r\n\t * @return Y\r\n\t */\r\n\tpublic getTooltipY(): number {\r\n\t\tlet y = this.getPropertyValue(\"tooltipY\");\r\n\t\tif (!(y instanceof Percent)) {\r\n\t\t\ty = percent(50);\r\n\t\t}\r\n\t\tif (y instanceof Percent) {\r\n\t\t\treturn this.positionToPoint(y.value).y;\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * When line is plotted, if its `shortestDistance` is set to `true` it is\r\n\t * bent according to the used projection, to depict the shortest distance how\r\n\t * it would go on the actual land.\r\n\t *\r\n\t * `precision` introduces a setting which can control when such bending\r\n\t * occurs.\r\n\t *\r\n\t * If the distance (in degrees) between line start and end points\r\n\t * is less than `precision`, no bending will take place and the line will be\r\n\t * straight.\r\n\t *\r\n\t * Set to large number (e.g. 10000) for perfectly straight line.\r\n\t *\r\n\t * @since 4.9.1\r\n\t * @default 0.1\r\n\t * @param value Precision\r\n\t */\r\n\tpublic set precision(value: number) {\r\n\t\tthis.setPropertyValue(\"precision\", value, true);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Precision\r\n\t */\r\n\tpublic get precision(): number {\r\n\t\treturn this.getPropertyValue(\"precision\");\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapLine\"] = MapLine;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapLine.ts","/**\r\n * Map line series module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapSeries, MapSeriesDataItem, GEOJSONGeometry, IMapSeriesProperties, IMapSeriesDataFields, IMapSeriesAdapters, IMapSeriesEvents } from \"./MapSeries\";\r\nimport { MapChart } from \"../types/MapChart\";\r\nimport { MapLine } from \"./MapLine\";\r\nimport { ListTemplate, ListDisposer } from \"../../core/utils/List\";\r\nimport { IMapLineDataObject } from \"../types/MapChart\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport * as $mapUtils from \"./MapUtils\";\r\nimport * as $array from \"../../core/utils/Array\";\r\nimport * as $utils from \"../../core/utils/Utils\";\r\nimport * as $iter from \"../../core/utils/Iterator\";\r\nimport { Disposer } from \"../../core/utils/Disposer\";\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[MapLineSeries]]\r\n * @see {@link DataItem}\r\n */\r\nexport class MapLineSeriesDataItem extends MapSeriesDataItem {\r\n\r\n\t/**\r\n\t * A [[MapLine]] element related to this data item.\r\n\t */\r\n\tpublic _mapLine: MapLine;\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a single-segment line.\r\n\t */\r\n\tprotected _line: Array<[number, number]>;\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-segment line.\r\n\t */\r\n\tprotected _multiLine: Array>;\r\n\r\n\t/**\r\n\t * A collection of lat/long coordinates for a single-segment line.\r\n\t */\r\n\tprotected _geoLine: Array;\r\n\r\n\t/**\r\n\t * A collection of lat/long coordinates for a multi-segment line.\r\n\t */\r\n\tprotected _multiGeoLine: Array>;\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for\r\n\t */\r\n\tpublic _component!: MapLineSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapLineSeriesDataItem\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\tpublic getFeature(): { \"type\": \"Feature\", geometry: { type: \"MultiLineString\", coordinates: Array> } } {\r\n\t\tif (this.multiLine && this.multiLine.length > 0) {\r\n\t\t\treturn { \"type\": \"Feature\", geometry: { type: \"MultiLineString\", coordinates: this.multiLine } };\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * A [[MapLine]] element related to this data item.\r\n\t *\r\n\t * @readonly\r\n\t * @return Element\r\n\t */\r\n\tpublic get mapLine(): this[\"_mapLine\"] {\r\n\t\tif (!this._mapLine) {\r\n\t\t\tlet mapLine = this.component.mapLines.create();\r\n\r\n\t\t\tthis._mapLine = mapLine;\r\n\t\t\tthis.addSprite(mapLine);\r\n\r\n\t\t\tthis._disposers.push(mapLine);\r\n\t\t\tthis._disposers.push(new Disposer(() => {\r\n\t\t\t\tif (this.component) {\r\n\t\t\t\t\tthis.component.mapLines.removeValue(mapLine);\r\n\t\t\t\t}\r\n\t\t\t}));\r\n\r\n\t\t\tthis.mapObject = mapLine;\r\n\t\t}\r\n\t\treturn this._mapLine;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a single-segment line. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * [ 100, 150 ],\r\n\t * [ 120, 200 ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @param line Coordinates\r\n\t */\r\n\tpublic set line(line: Array<[number, number]>) {\r\n\t\tthis._line = line;\r\n\t\tthis.multiLine = [line];\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get line(): Array<[number, number]> {\r\n\t\treturn this._line;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-segment line. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * // Segment 1\r\n\t * [\r\n\t * [ 100, 150 ],\r\n\t * [ 120, 200 ]\r\n\t * ],\r\n\t *\r\n\t * // Segment 2\r\n\t * [\r\n\t * [ 120, 200 ],\r\n\t * [ 150, 100 ]\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @param multiLine Coordinates\r\n\t */\r\n\tpublic set multiLine(multiLine: Array>) {\r\n\t\tthis._multiLine = multiLine;\r\n\t\tthis._multiGeoLine = $mapUtils.multiLineToGeo(multiLine);\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get multiLine(): Array> {\r\n\t\treturn this._multiLine;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of lat/long coordinates for a single-segment line. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * { longitude: 3.121, latitude: 0.58 },\r\n\t * { longitude: -5.199, latitude: 21.223 }\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @see {@link https://tools.ietf.org/html/rfc7946#section-3.1.4} GeoJSON LineString reference\r\n\t * @param geoLine Coordinates\r\n\t */\r\n\tpublic set geoLine(geoLine: Array) {\r\n\t\tthis._geoLine = geoLine;\r\n\t\tthis.multiLine = $mapUtils.multiGeoLineToMultiLine([geoLine]);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get geoLine(): Array {\r\n\t\treturn this._geoLine;\r\n\t}\r\n\r\n\t/**\r\n\t * A collection of X/Y coordinates for a multi-segment line. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * [\r\n\t * // Segment 1\r\n\t * [\r\n\t * { longitude: 3.121, latitude: 0.58 },\r\n\t * { longitude: -5.199, latitude: 21.223 }\r\n\t * ],\r\n\t *\r\n\t * // Segment 2\r\n\t * [\r\n\t * { longitude: -5.199, latitude: 21.223 },\r\n\t * { longitude: -12.9, latitude: 25.85 }\r\n\t * ]\r\n\t * ]\r\n\t * ```\r\n\t *\r\n\t * @see {@link https://tools.ietf.org/html/rfc7946#section-3.1.5} GeoJSON MultiLineString reference\r\n\t * @param multiGeoLine Coordinates\r\n\t */\r\n\tpublic set multiGeoLine(multiGeoLine: Array>) {\r\n\t\tthis._multiGeoLine = multiGeoLine;\r\n\t\tthis.multiLine = $mapUtils.multiGeoLineToMultiLine(multiGeoLine);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get multiGeoLine(): Array> {\r\n\t\treturn this._multiGeoLine;\r\n\t}\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines data fields for [[MapLineSeries]].\r\n */\r\nexport interface IMapLineSeriesDataFields extends IMapSeriesDataFields {\r\n\r\n\t/**\r\n\t * Field name that holds line data in pixels.\r\n\t */\r\n\tline?: string;\r\n\r\n\t/**\r\n\t * Field name that holds multi-line data in pixels.\r\n\t */\r\n\tmultiLine?: string;\r\n\r\n\t/**\r\n\t * Field name that holds line data in Geo coordinates.\r\n\t */\r\n\tgeoLine?: string;\r\n\r\n\t/**\r\n\t * Field name that holds multi-line data in Geo coordinates.\r\n\t */\r\n\tmultiGeoLine?: string;\r\n\r\n}\r\n\r\n/**\r\n * Defines properties for [[MapLineSeries]].\r\n */\r\nexport interface IMapLineSeriesProperties extends IMapSeriesProperties { }\r\n\r\n/**\r\n * Defines events for [[MapLineSeries]].\r\n */\r\nexport interface IMapLineSeriesEvents extends IMapSeriesEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapLineSeries]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapLineSeriesAdapters extends IMapSeriesAdapters, IMapLineSeriesProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * A series of map line series.\r\n *\r\n * @see {@link IMapLineSeriesEvents} for a list of available Events\r\n * @see {@link IMapLineSeriesAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class MapLineSeries extends MapSeries {\r\n\r\n\t/**\r\n\t * Defines available data fields.\r\n\t */\r\n\tpublic _dataFields: IMapLineSeriesDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapLineSeriesProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapLineSeriesAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapLineSeriesEvents;\r\n\r\n\t/**\r\n\t * Defines the type of data item.\r\n\t */\r\n\tpublic _dataItem: MapLineSeriesDataItem;\r\n\r\n\r\n\t/**\r\n\t * A related chart/map object, this element is drawn on.\r\n\t */\r\n\tpublic chart: MapChart;\r\n\r\n\t/**\r\n\t * Defines the type of the line items in this series.\r\n\t */\r\n\tpublic _mapLine: MapLine;\r\n\r\n\t/**\r\n\t * A list of map lins in the series.\r\n\t */\r\n\tprotected _mapLines: ListTemplate;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapLineSeries\";\r\n\r\n\t\t// Set data fields\r\n\t\tthis.dataFields.multiLine = \"multiLine\";\r\n\t\tthis.dataFields.line = \"line\";\r\n\r\n\t\tthis.dataFields.geoLine = \"geoLine\";\r\n\t\tthis.dataFields.multiGeoLine = \"multiGeoLine\";\r\n\r\n\t\tthis.ignoreBounds = true;\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new/empty DataItem of the type appropriate for this object.\r\n\t *\r\n\t * @see {@link DataItem}\r\n\t * @return Data Item\r\n\t */\r\n\tprotected createDataItem(): this[\"_dataItem\"] {\r\n\t\treturn new MapLineSeriesDataItem();\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates series data, effectively causing the whole series to be\r\n\t * redrawn.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validateData(): void {\r\n\t\t// process geoJSON and created map objects\r\n\t\tif (this.useGeodata || this.geodata) {\r\n\t\t\tlet geoJSON: any = this.chart.geodata;\r\n\t\t\tif (geoJSON) {\r\n\r\n\t\t\t\tlet features: any[];\r\n\r\n\t\t\t\tif (geoJSON.type == \"FeatureCollection\") {\r\n\t\t\t\t\tfeatures = geoJSON.features;\r\n\t\t\t\t}\r\n\t\t\t\telse if (geoJSON.type == \"Feature\") {\r\n\t\t\t\t\tfeatures = [geoJSON];\r\n\t\t\t\t}\r\n\t\t\t\telse if ([\"Point\", \"LineString\", \"Polygon\", \"MultiPoint\", \"MultiLineString\", \"MultiPolygon\"].indexOf(geoJSON.type) != -1) {\r\n\t\t\t\t\tfeatures = [{ geometry: geoJSON }];\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tconsole.log(\"nothing found in geoJSON\");\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (features) {\r\n\t\t\t\t\tfor (let i = 0, len = features.length; i < len; i++) {\r\n\r\n\t\t\t\t\t\tlet feature: any = features[i];\r\n\t\t\t\t\t\tlet geometry: any = feature.geometry;\r\n\t\t\t\t\t\tif (geometry) {\r\n\t\t\t\t\t\t\tlet type: GEOJSONGeometry = geometry.type;\r\n\t\t\t\t\t\t\tlet id: string = feature.id;\r\n\t\t\t\t\t\t\tif (type == \"LineString\" || type == \"MultiLineString\") {\r\n\r\n\t\t\t\t\t\t\t\tif (!this.checkInclude(this.include, this.exclude, id)) {\r\n\t\t\t\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tlet coordinates: any[] = geometry.coordinates;\r\n\t\t\t\t\t\t\t\tlet dataObject: IMapLineDataObject = $array.find(this.data, (value, i) => {\r\n\t\t\t\t\t\t\t\t\treturn value.id == id;\r\n\t\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\t\tif (type == \"LineString\") {\r\n\t\t\t\t\t\t\t\t\tcoordinates = [coordinates];\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tif (!dataObject) {\r\n\t\t\t\t\t\t\t\t\tdataObject = { multiLine: coordinates, id: id, madeFromGeoData:true};\r\n\t\t\t\t\t\t\t\t\tthis.data.push(dataObject);\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t\t\tif (!dataObject.multiLine) {\r\n\t\t\t\t\t\t\t\t\t\tdataObject.multiLine = coordinates;\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t// copy properties data to datacontext\r\n\t\t\t\t\t\t\t\t$utils.softCopyProperties(feature.properties, dataObject);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tsuper.validateData();\r\n\t}\r\n\r\n\t/**\r\n\t * A list of lines in the series.\r\n\t *\r\n\t * @return Lines\r\n\t */\r\n\tpublic get mapLines(): ListTemplate {\r\n\r\n\t\tif (!this._mapLines) {\r\n\t\t\tlet lineTemplate: MapLine = this.createLine();\r\n\t\t\tlet mapLines = new ListTemplate(lineTemplate);\r\n\t\t\tthis._disposers.push(new ListDisposer(mapLines));\r\n\t\t\tthis._disposers.push(mapLines.template);\r\n\t\t\tmapLines.events.on(\"inserted\", this.handleObjectAdded, this, false);\r\n\t\t\tthis._mapLines = mapLines;\r\n\t\t\tthis._mapObjects = mapLines;\r\n\t\t}\r\n\r\n\t\treturn this._mapLines;\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new line instance of suitable type.\r\n\t *\r\n\t * @return New line\r\n\t */\r\n\tprotected createLine(): this[\"_mapLine\"] {\r\n\t\treturn new MapLine();\r\n\t}\r\n\r\n\t/**\r\n\t * (Re)validates the series\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validate() {\r\n\r\n\t\tthis.dataItems.each((dataItem) => {\r\n\t\t\t$utils.used(dataItem.mapLine);\r\n\t\t})\r\n\r\n\r\n\t\tsuper.validate();\r\n\t\tthis.mapLines.each((mapLine) => {\r\n\t\t\tmapLine.validate();\r\n\t\t})\r\n\t}\r\n\r\n\t/**\r\n\t * Copies all properties from another instance of [[Series]].\r\n\t *\r\n\t * @param source Source series\r\n\t */\r\n\tpublic copyFrom(source: this) {\r\n\t\tthis.mapLines.template.copyFrom(source.mapLines.template);\r\n\t\tsuper.copyFrom(source);\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic getFeatures(): { \"type\": \"Feature\", geometry: { type: \"MultiLineString\", coordinates: Array> } }[] {\r\n\t\tlet features: { \"type\": \"Feature\", geometry: { type: \"MultiLineString\", coordinates: Array> } }[] = [];\r\n\t\tthis.dataItems.each((dataItem) => {\r\n\t\t\tlet feature = dataItem.getFeature();\r\n\t\t\tif (feature) {\r\n\t\t\t\tfeatures.push(feature);\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\tthis.mapLines.each((mapLine) => {\r\n\t\t\tif (this.dataItems.indexOf(mapLine._dataItem) == -1) {\r\n\t\t\t\tlet feature = mapLine.getFeature();\r\n\t\t\t\tif (feature) {\r\n\t\t\t\t\tfeatures.push(feature);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t})\r\n\t\treturn features;\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * returns MapLine by id\r\n\t * @param line id\r\n\t * @return {MapLine}\r\n\t */\r\n\tpublic getLineById(id: string): MapLine {\r\n\t\treturn $iter.find(this.mapLines.iterator(), (mapLine) => {\r\n\t\t\tlet dataContext: any = mapLine.dataItem.dataContext;\r\n\t\t\treturn dataContext.id == id;\r\n\t\t});\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapLineSeries\"] = MapLineSeries;\r\nregistry.registeredClasses[\"MapLineSeriesDataItem\"] = MapLineSeriesDataItem;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapLineSeries.ts","/**\r\n * Graticule (map grid line).\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapLine, IMapLineProperties, IMapLineAdapters, IMapLineEvents } from \"./MapLine\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport { GraticuleSeries } from \"./GraticuleSeries\";\r\nimport { Polyline } from \"../../core/elements/Polyline\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[Graticule]].\r\n */\r\nexport interface IGraticuleProperties extends IMapLineProperties { }\r\n\r\n/**\r\n * Defines events for [[Graticule]].\r\n */\r\nexport interface IGraticuleEvents extends IMapLineEvents { }\r\n\r\n/**\r\n * Defines adapters for [[Graticule]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IGraticuleAdapters extends IMapLineAdapters, IGraticuleProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Graticule is a map line spanning from the poles or around the globe.\r\n *\r\n * @since 4.3.0\r\n * @see {@link IGraticuleEvents} for a list of available events\r\n * @see {@link IGraticuleAdapters} for a list of available Adapters\r\n */\r\nexport class Graticule extends MapLine {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IGraticuleProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IGraticuleAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IGraticuleEvents;\r\n\r\n\t/**\r\n\t * A visual element.\r\n\t */\r\n\tpublic line: Polyline;\r\n\r\n\t/**\r\n\t * A map series this object belongs to.\r\n\t */\r\n\tpublic series: GraticuleSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"Graticule\";\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t\tthis.shortestDistance = true;\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"Graticule\"] = Graticule;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/Graticule.ts","/**\r\n * Graticule (map grid) series functionality.\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapLineSeries, MapLineSeriesDataItem, IMapLineSeriesProperties, IMapLineSeriesDataFields, IMapLineSeriesAdapters, IMapLineSeriesEvents } from \"./MapLineSeries\";\r\nimport { Graticule } from \"./Graticule\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\nimport * as $array from \"../../core/utils/Array\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[GraticuleSeries]].\r\n *\r\n * @see {@link DataItem}\r\n */\r\nexport class GraticuleSeriesDataItem extends MapLineSeriesDataItem {\r\n\r\n\t/**\r\n\t * A [[Graticule]] element related to this data item.\r\n\t */\r\n\tpublic _mapLine: Graticule;\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for.\r\n\t */\r\n\tpublic _component!: GraticuleSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"GraticuleSeriesDataItem\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines data fields for [[GraticuleSeries]].\r\n */\r\nexport interface IGraticuleSeriesDataFields extends IMapLineSeriesDataFields { }\r\n\r\n/**\r\n * Defines properties for [[GraticuleSeries]].\r\n */\r\nexport interface IGraticuleSeriesProperties extends IMapLineSeriesProperties {\r\n\t/**\r\n\t * Draw a graticule (grid) every X degrees of latitude.\r\n\t *\r\n\t * @default 10\r\n\t */\r\n\tlatitudeStep?: number;\r\n\r\n\t/**\r\n\t * Draw a graticule (grid) every X degrees of longitude.\r\n\t *\r\n\t * @default 10\r\n\t */\r\n\tlongitudeStep?: number;\r\n\r\n\t/**\r\n\t * Draw a thicker (major) graticule every X degrees of latitude.\r\n\t *\r\n\t * @default 90\r\n\t */\r\n\t// majorLatitudeStep?: number;\r\n\r\n\t/**\r\n\t * Draw a thicker (major) graticule every X degrees of longitude.\r\n\t *\r\n\t * @default 360\r\n\t */\r\n\t// majorLongitudeStep?: number;\r\n\r\n\t/**\r\n\t * Whether to cap graticules (grid) to actual span of the map (`true`), e.g.\r\n\t * where there are polygons, or draw full-world grid (`false`).\r\n\t *\r\n\t * For world maps, using `false` makes sense. For smaller maps - not so much.\r\n\t *\r\n\t * If set to `false`, the grid will be drawn from this series `east` to\r\n\t * `west`, and from `south` to `north` (default values: `east = -180`;\r\n\t * `west = 180`; `south =-90`; `north =90`).\r\n\t *\r\n\t * These can be overridden by setting `GraticuleSeries`' respective\r\n\t * properties.\r\n\t *\r\n\t * @default true\r\n\t */\r\n\tfitExtent?: boolean;\r\n\r\n\t/**\r\n\t * Whether to draw all the grid as a single element or as separate lines.\r\n\t *\r\n\t * Setting `true` (default) will result in better performance, whereas\r\n\t * `false` allows setting visual properties of each line individually.\r\n\t *\r\n\t * @default true\r\n\t */\r\n\tsingleSprite?: boolean;\r\n}\r\n\r\n/**\r\n * Defines events for [[GraticuleSeries]].\r\n */\r\nexport interface IGraticuleSeriesEvents extends IMapLineSeriesEvents { }\r\n\r\n/**\r\n * Defines adapters for [[GraticuleSeries]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IGraticuleSeriesAdapters extends IMapLineSeriesAdapters, IGraticuleSeriesProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * This class is used to create a set of graticules (map grid).\r\n *\r\n * To enable, create like you would create any regular map series:\r\n *\r\n * ```TypeScript\r\n * let graticule = chart.series.push(new am4maps.GraticuleSeries())\r\n * graticule.mapLines.template.line.stroke = am4core.color(\"#000000\");\r\n * graticule.mapLines.template.line.strokeOpacity = 0.1;\r\n * ```\r\n * ```JavaScript\r\n * var graticule = chart.series.push(new am4maps.GraticuleSeries())\r\n * graticule.mapLines.template.line.stroke = am4core.color(\"#000000\");\r\n * graticule.mapLines.template.line.strokeOpacity = 0.1;\r\n * ```\r\n * ```JSON\r\n * {\r\n * // ...\r\n * \"series\": [{\r\n * \"type\": \"GraticuleSeries\",\r\n * \"mapLines\": {\r\n * \"line\": {\r\n * \"stroke\": \"#000000\",\r\n * \"strokeOpacity\": 0.1\r\n * }\r\n * }\r\n * }]\r\n * }\r\n * ```\r\n *\r\n * @since 4.3.0\r\n * @see {@link IGraticuleSeriesEvents} for a list of available Events\r\n * @see {@link IGraticuleSeriesAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class GraticuleSeries extends MapLineSeries {\r\n\r\n\t/**\r\n\t * Defines available data fields.\r\n\t */\r\n\tpublic _dataFields: IGraticuleSeriesDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IGraticuleSeriesProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IGraticuleSeriesAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IGraticuleSeriesEvents;\r\n\r\n\t/**\r\n\t * Defines the type of data item.\r\n\t */\r\n\tpublic _dataItem: GraticuleSeriesDataItem;\r\n\r\n\t/**\r\n\t * Defines the type of the line items in this series.\r\n\t */\r\n\tpublic _mapLine: Graticule;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"GraticuleSeries\";\r\n\r\n\t\tthis.longitudeStep = 10;\r\n\r\n\t\tthis.latitudeStep = 10;\r\n\r\n\t\tthis.north = 90;\r\n\t\tthis.south = -90;\r\n\t\tthis.east = -180;\r\n\t\tthis.west = 180;\r\n\r\n\t\t//this.majorLatitudeStep = 90;\r\n\t\t//this.majorLongitudeStep = 360;\r\n\r\n\t\tthis.fitExtent = true;\r\n\r\n\t\tthis.singleSprite = true;\r\n\r\n\t\tthis.events.disableType(\"geoBoundsChanged\");\r\n\r\n\t\tthis.mapLines.template.line.strokeOpacity = 0.08;\r\n\r\n\t\tthis.ignoreBounds = false;\r\n\r\n\t\tthis.hiddenInLegend = true;\r\n\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new/empty DataItem of the type appropriate for this object.\r\n\t *\r\n\t * @see {@link DataItem}\r\n\t * @return Data Item\r\n\t */\r\n\tprotected createDataItem(): this[\"_dataItem\"] {\r\n\t\treturn new GraticuleSeriesDataItem();\r\n\t}\r\n\r\n\tpublic validateData() {\r\n\t\tsuper.validateData();\r\n\r\n\t\tthis.mapLines.clear();\r\n\r\n\t\tlet graticule = d3geo.geoGraticule();\r\n\r\n\t\tif (graticule) {\r\n\t\t\tgraticule.stepMinor([this.longitudeStep, this.latitudeStep]);\r\n\t\t\tgraticule.stepMajor([360, 360]);\r\n\r\n\t\t\tlet chart = this.chart;\r\n\t\t\tif (this.fitExtent) {\r\n\t\t\t\tgraticule.extent([[chart.east, chart.north], [chart.west, chart.south]]);\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tgraticule.extent([[this.east, this.north], [this.west, this.south]]);\r\n\t\t\t}\r\n\r\n\t\t\tif (this.singleSprite) {\r\n\t\t\t\tlet mapLine = this.mapLines.create();\r\n\t\t\t\tmapLine.multiLine = graticule().coordinates as Array>;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tlet lineStrings = graticule.lines();\r\n\r\n\t\t\t\t$array.each(lineStrings, (lineString) => {\r\n\t\t\t\t\tlet mapLine = this.mapLines.create();\r\n\t\t\t\t\tmapLine.multiLine = [lineString.coordinates as Array<[number, number]>];\r\n\t\t\t\t})\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new line instance of suitable type.\r\n\t *\r\n\t * @return New line\r\n\t */\r\n\tprotected createLine(): this[\"_mapLine\"] {\r\n\t\treturn new Graticule();\r\n\t}\r\n\r\n\t/**\r\n\t * Draw a graticule (grid) every X degrees of latitude.\r\n\t *\r\n\t * @default 10\r\n\t * @param value Step\r\n\t */\r\n\tpublic set latitudeStep(value: number) {\r\n\t\tif (this.setPropertyValue(\"latitudeStep\", value)) {\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Step\r\n\t */\r\n\tpublic get latitudeStep(): number {\r\n\t\treturn this.getPropertyValue(\"latitudeStep\");\r\n\t}\r\n\r\n\t/**\r\n\t * Draw a graticule (grid) every X degrees of longitude.\r\n\t *\r\n\t * @default 10\r\n\t * @param value Step\r\n\t */\r\n\tpublic set longitudeStep(value: number) {\r\n\t\tif (this.setPropertyValue(\"longitudeStep\", value)) {\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Step\r\n\t */\r\n\tpublic get longitudeStep(): number {\r\n\t\treturn this.getPropertyValue(\"longitudeStep\");\r\n\t}\r\n\r\n\t/**\r\n\t * Draw a thicker (major) graticule every X degrees of latitude.\r\n\t *\r\n\t * @default 90\r\n\t * @param value Step\r\n\t */\r\n\t// public set majorLatitudeStep(value: number) {\r\n\t// \tif (this.setPropertyValue(\"majorLatitudeStep\", value)) {\r\n\t// \t\tthis.invalidateData();\r\n\t// \t}\r\n\t// }\r\n\r\n\t/**\r\n\t * @return Step\r\n\t */\r\n\t// public get majorLatitudeStep(): number {\r\n\t// \treturn this.getPropertyValue(\"majorLatitudeStep\");\r\n\t// }\r\n\r\n\t/**\r\n\t * Draw a thicker (major) graticule every X degrees of longitude.\r\n\t *\r\n\t * @default 360\r\n\t * @param value Step\r\n\t */\r\n\t// public set majorLongitudeStep(value: number) {\r\n\t// \tif (this.setPropertyValue(\"majorLongitudeStep\", value)) {\r\n\t// \t\tthis.invalidateData();\r\n\t// \t}\r\n\t// }\r\n\r\n\t/**\r\n\t * @return Step\r\n\t */\r\n\t// public get majorLongitudeStep(): number {\r\n\t// \treturn this.getPropertyValue(\"majorLongitudeStep\");\r\n\t// }\r\n\r\n\t/**\r\n\t * Whether to cap graticules (grid) to actual span of the map (`true`), e.g.\r\n\t * where there are polygons, or draw full-world grid (`false`).\r\n\t *\r\n\t * For world maps, using `false` makes sense. For smaller maps - not so much.\r\n\t *\r\n\t * If set to `false`, the grid will be drawn from this series `east` to\r\n\t * `west`, and from `south` to `north` (default values: `east = -180`;\r\n\t * `west = 180`; `south =-90`; `north =90`).\r\n\t *\r\n\t * These can be overridden by setting `GraticuleSeries`' respective\r\n\t * properties.\r\n\t *\r\n\t * @default true\r\n\t * @param value Fit?\r\n\t */\r\n\tpublic set fitExtent(value: boolean) {\r\n\t\tif (this.setPropertyValue(\"fitExtent\", value)) {\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Fit?\r\n\t */\r\n\tpublic get fitExtent(): boolean {\r\n\t\treturn this.getPropertyValue(\"fitExtent\");\r\n\t}\r\n\r\n\t/**\r\n\t * Whether to draw all the grid as a single element or as separate lines.\r\n\t *\r\n\t * Setting `true` (default) will result in better performance, whereas\r\n\t * `false` allows setting visual properties of each line individually.\r\n\t *\r\n\t * @default true\r\n\t * @param value Use single sprite?\r\n\t */\r\n\tpublic set singleSprite(value: boolean) {\r\n\t\tif (this.setPropertyValue(\"singleSprite\", value)) {\r\n\t\t\tthis.invalidateData();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Use single sprite?\r\n\t */\r\n\tpublic get singleSprite(): boolean {\r\n\t\treturn this.getPropertyValue(\"singleSprite\");\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"GraticuleSeries\"] = GraticuleSeries;\r\nregistry.registeredClasses[\"GraticuleSeriesDataItem\"] = GraticuleSeriesDataItem;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/GraticuleSeries.ts","/**\r\n * Map module.\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { SerialChart, ISerialChartProperties, ISerialChartDataFields, ISerialChartAdapters, ISerialChartEvents, SerialChartDataItem } from \"./SerialChart\";\r\nimport { Sprite, ISpriteEvents, AMEvent } from \"../../core/Sprite\";\r\nimport { IDisposer, Disposer } from \"../../core/utils/Disposer\";\r\nimport { InterfaceColorSet } from \"../../core/utils/InterfaceColorSet\";\r\nimport { MapSeries } from \"../map/MapSeries\";\r\nimport { MapObject } from \"../map/MapObject\";\r\nimport { MapImage } from \"../map/MapImage\";\r\nimport { MapPolygon } from \"../map/MapPolygon\";\r\nimport { MapPolygonSeries } from \"../map/MapPolygonSeries\";\r\nimport { IPoint } from \"../../core/defs/IPoint\";\r\nimport { IGeoPoint } from \"../../core/defs/IGeoPoint\";\r\nimport { DataSource } from \"../../core/data/DataSource\";\r\nimport { Projection } from \"../map/projections/Projection\";\r\nimport { ZoomControl } from \"../map/ZoomControl\";\r\nimport { Ordering } from \"../../core/utils/Order\";\r\nimport { Circle } from \"../../core/elements/Circle\";\r\nimport { SmallMap } from \"../map/SmallMap\";\r\nimport * as $mapUtils from \"../map/MapUtils\";\r\nimport { Animation } from \"../../core/utils/Animation\";\r\nimport { keyboard } from \"../../core/utils/Keyboard\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport { options } from \"../../core/Options\";\r\nimport * as $math from \"../../core/utils/Math\";\r\nimport * as $utils from \"../../core/utils/Utils\";\r\nimport * as $ease from \"../../core/utils/Ease\";\r\nimport * as $iter from \"../../core/utils/Iterator\";\r\nimport * as $type from \"../../core/utils/Type\";\r\nimport * as $geo from \"../map/Geo\";\r\nimport { Paper } from \"../../core/rendering/Paper\";\r\nimport { IListEvents } from \"../../core/utils/List\";\r\nimport { GraticuleSeries } from \"../map/GraticuleSeries\";\r\nimport { getInteraction, IInteractionEvents } from \"../../core/interaction/Interaction\";\r\nimport { Legend } from \"../Legend\";\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[MapChart]].\r\n *\r\n * @see {@link DataItem}\r\n */\r\nexport class MapChartDataItem extends SerialChartDataItem {\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for.\r\n\t */\r\n\tpublic _component!: MapChart;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapChartDataItem\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines interface for a map polygon object.\r\n */\r\nexport interface IMapPolygonDataObject {\r\n\r\n\t/**\r\n\t * A unique id of the object.\r\n\t */\r\n\tid?: string;\r\n\r\n\t/**\r\n\t * Numeric value for heat-map scenarios.\r\n\t */\r\n\tvalue?: number;\r\n\r\n\t/**\r\n\t * Single polygon information in X/Y coordinates.\r\n\t */\r\n\tpolygon?: Array>;\r\n\r\n\t/**\r\n\t * Multi-part polygon information in X/Y coordinates.\r\n\t */\r\n\tmultiPolygon?: Array>>;\r\n\r\n\t/**\r\n\t * Single polygon information in lat/long geo-coordinates.\r\n\t */\r\n\tgeoPolygon?: Array>;\r\n\r\n\t/**\r\n\t * Multi-part polygon information in lat/long geo-coordinates.\r\n\t */\r\n\tmultiGeoPolygon?: Array>>;\r\n\r\n\t/**\r\n\t * flag indicating whether this data item was created from geo data\r\n\t */\r\n\tmadeFromGeoData?: boolean;\r\n}\r\n\r\n/**\r\n * Defines types of map line.\r\n */\r\nexport type MapLineType = \"line\" | \"arc\" | \"spline\" | \"realTrajectory\";\r\n\r\n/**\r\n * Defines interface for the map line object.\r\n */\r\nexport interface IMapLineDataObject {\r\n\r\n\t/**\r\n\t * A unique id of the object.\r\n\t */\r\n\tid?: string;\r\n\r\n\t/**\r\n\t * Numeric value for heat-map scenarios.\r\n\t */\r\n\tvalue?: number;\r\n\r\n\t/**\r\n\t * Single line information in X/Y coordinates.\r\n\t */\r\n\tline?: Array<[number, number]>;\r\n\r\n\t/**\r\n\t * Multi-part line information in X/Y coordinates.\r\n\t */\r\n\tmultiLine?: Array>;\r\n\r\n\t/**\r\n\t * Single line information in lat/long geo-coordinates.\r\n\t */\r\n\tgeoLine?: Array;\r\n\r\n\t/**\r\n\t * Multi-part line information in lat/long geo-coordinates.\r\n\t */\r\n\tmultiGeoLine?: Array>;\r\n\r\n\t/**\r\n\t * flag indicating whether this data item was created from geo data\r\n\t */\r\n\tmadeFromGeoData?: boolean;\r\n\r\n}\r\n\r\n/**\r\n * Defines interface for a map image (market) object.\r\n */\r\nexport interface IMapImageDataObject {\r\n\r\n\t/**\r\n\t * A unique id of the object.\r\n\t */\r\n\tid?: string;\r\n\r\n\t/**\r\n\t * Numeric value for heat-map scenarios.\r\n\t */\r\n\tvalue?: number;\r\n\r\n\t/**\r\n\t * Image position information in X/Y coordinates.\r\n\t */\r\n\tpoint?: [number, number];\r\n\r\n\t/**\r\n\t * Multi-image position information in X/Y coordinates.\r\n\t */\r\n\tmultiPoint?: Array<[number, number]>;\r\n\r\n\t/**\r\n\t * Image position information in lat/long geo-coordinates.\r\n\t */\r\n\tgeoPoint?: IGeoPoint;\r\n\r\n\t/**\r\n\t * Multi-image position information in lat/long geo-coordinates.\r\n\t */\r\n\tmultiGeoPoint?: Array;\r\n\r\n\r\n\t/**\r\n\t * flag indicating whether this data item was created from geo data\r\n\t */\r\n\tmadeFromGeoData?: boolean;\r\n}\r\n\r\n/**\r\n * Defines type suitable for all map objects.\r\n */\r\nexport type IMapDataObject = IMapPolygonDataObject | IMapLineDataObject;\r\n\r\n/**\r\n * Defines data fields for [[MapChart]].\r\n */\r\nexport interface IMapChartDataFields extends ISerialChartDataFields { }\r\n\r\n/**\r\n * Defines properties for [[MapChart]].\r\n */\r\nexport interface IMapChartProperties extends ISerialChartProperties {\r\n\r\n\t/**\r\n\t * Projection to be used when drawing the map.\r\n\t */\r\n\tprojection?: Projection;\r\n\r\n\t/**\r\n\t * Degrees to rotate the map around vertical axis (Y).\r\n\t *\r\n\t * E.g. if set to -160, the longitude 20 will become a new center, creating\r\n\t * a Pacific-centered map.\r\n\t */\r\n\tdeltaLongitude?: number;\r\n\r\n\t/**\r\n\t * Degrees to rotate the map around horizontal axis (X).\r\n\t *\r\n\t * E.g. setting this to -90 will put Antarctica directly in the center of\r\n\t * the map.\r\n\t *\r\n\t * @since 4.3.0\r\n\t */\r\n\tdeltaLatitude?: number;\r\n\r\n\t/**\r\n\t * Degrees to rotate the map around horizontal \"Z\" - an axis that goes from\r\n\t * the center of the globe directly to the viewer.\r\n\t *\r\n\t * @since 4.3.0\r\n\t */\r\n\tdeltaGamma?: number;\r\n\r\n\t/**\r\n\t * Maximum portion of the map's width/height to allow panning \"off screen\".\r\n\t *\r\n\t * A value of 0 (zero) will prevent any portion of the the map to be panned\r\n\t * outside the viewport.\r\n\t *\r\n\t * 0.5 will allow half of the map to be outside viewable area.\r\n\t *\r\n\t * @default 0.7\r\n\t */\r\n\tmaxPanOut?: number;\r\n\r\n\t/**\r\n\t * A map will start centered on this geographical point.\r\n\t */\r\n\thomeGeoPoint?: IGeoPoint;\r\n\r\n\t/**\r\n\t * A map will start zoomed to this level.\r\n\t */\r\n\thomeZoomLevel?: number;\r\n\r\n\t/**\r\n\t * When user zooms in or out current zoom level is multiplied or divided\r\n\t * by value of this setting.\r\n\t *\r\n\t * @default 2\r\n\t */\r\n\tzoomStep?: number;\r\n\r\n\t/**\r\n\t * Specifies what should chart do if when mouse wheel is rotated.\r\n\t */\r\n\tmouseWheelBehavior?: \"zoom\" | \"none\";\r\n\r\n\t/**\r\n\t * What \"dragging\" map does.\r\n\t *\r\n\t * Available values:\r\n\t * * `\"move\"` (default): changes position of the map.\r\n\t * * `\"rotateLat\"`: changes `deltaLatitude` (rotates the globe vertically).\r\n\t * * `\"rotateLong\"`: changes `deltaLongitude` (rotates the globe horizontally).\r\n\t * * `\"rotateLongLat\"`: changes both `deltaLongitude` and `deltaLatitude` (rotates the globe in any direction).\r\n\t *\r\n\t * @default \"move\"\r\n\t * @since 4.3.0\r\n\t */\r\n\tpanBehavior?: \"move\" | \"rotateLat\" | \"rotateLong\" | \"rotateLongLat\";\r\n\r\n\t/**\r\n\t * Specifies if the map should be centered when zooming out\r\n\t * @default true\r\n\t * @since 4.7.12\r\n\t */\r\n\tcenterMapOnZoomOut?: boolean;\r\n\r\n\t/**\r\n\t * Indicates whether GeoJSON geodata supplied to the chart uses\r\n\t * ESRI (clockwise) or non-ESRI (counter-clockwise) order of the polygon\r\n\t * coordinates.\r\n\t *\r\n\t * `MapChart` supports only ESRI standard, so if your custom maps appears\r\n\t * garbled, try setting `reverseGeodata = true`.\r\n\t * \r\n\t * @default false\r\n\t * @since 4.10.11\r\n\t */\r\n\treverseGeodata?: boolean;\r\n\r\n}\r\n\r\n/**\r\n * Defines events for [[MapChart]].\r\n */\r\nexport interface IMapChartEvents extends ISerialChartEvents {\r\n\r\n\t/**\r\n\t * Invoked when map is zoomed in or out.\r\n\t */\r\n\tzoomlevelchanged: {};\r\n\r\n\t/**\r\n\t * Invoked when map is panned. (moved)\r\n\t */\r\n\tmappositionchanged: {};\r\n\r\n\t/**\r\n\t * Invoked when scale ratio is changed, e.g when the whole map area is\r\n\t * resized and the map needs to be resized to fit it, without changing\r\n\t * zoom level.\r\n\t */\r\n\tscaleratiochanged: {};\r\n\r\n}\r\n\r\n/**\r\n * Defines adapters for [[MapChart]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapChartAdapters extends ISerialChartAdapters, IMapChartProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Creates a map.\r\n *\r\n * @see {@link IMapChartEvents} for a list of available Events\r\n * @see {@link IMapChartAdapters} for a list of available Adapters\r\n * @see {@link https://www.amcharts.com/docs/v4/chart-types/map/} for documentation\r\n */\r\nexport class MapChart extends SerialChart {\r\n\r\n\t/**\r\n\t * Available data fields.\r\n\t */\r\n\tpublic _dataFields: IMapChartDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapChartProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapChartAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapChartEvents;\r\n\r\n\t/**\r\n\t * The East-most longitude point of the map.\r\n\t */\r\n\tpublic east: number;\r\n\r\n\t/**\r\n\t * The West-most longitude point of the map.\r\n\t */\r\n\tpublic west: number;\r\n\r\n\t/**\r\n\t * The South-most latitude point of the map.\r\n\t */\r\n\tpublic south: number;\r\n\r\n\t/**\r\n\t * The North-most latitude point of the map.\r\n\t */\r\n\tpublic north: number;\r\n\r\n\t/**\r\n\t * A ratio to be used when scaling the map shapes.\r\n\t *\r\n\t * @readonly\r\n\t */\r\n\tpublic scaleRatio: number = 1;\r\n\r\n\t/**\r\n\t * A screen point of the map's center.\r\n\t *\r\n\t * @readonly\r\n\t */\r\n\tpublic centerPoint: IPoint;\r\n\r\n\t/**\r\n\t * A screen point of the map's left.\r\n\t *\r\n\t * @readonly\r\n\t */\r\n\tpublic westPoint: IPoint;\r\n\r\n\t/**\r\n\t * A screen point of the map's right.\r\n\t *\r\n\t * @readonly\r\n\t */\r\n\tpublic eastPoint: IPoint;\r\n\r\n\t/**\r\n\t * A screen point of the map's top.\r\n\t *\r\n\t * @readonly\r\n\t */\r\n\tpublic northPoint: IPoint;\r\n\r\n\t/**\r\n\t * A screen point of the map's bottom.\r\n\t *\r\n\t * @readonly\r\n\t */\r\n\tpublic southPoint: IPoint;\r\n\r\n\t/**\r\n\t * Width of the actual map objects (px).\r\n\t */\r\n\tpublic seriesWidth: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic seriesMaxLeft: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic seriesMaxRight: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic seriesMaxTop: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic seriesMaxBottom: number;\r\n\r\n\t/**\r\n\t * Height of the actual map objects (px).\r\n\t */\r\n\tpublic seriesHeight: number;\r\n\r\n\t/**\r\n\t * Map data in GeoJSON format.\r\n\t *\r\n\t * @see {@link http://geojson.org/} GeoJSON official specification\r\n\t */\r\n\tprotected _geodata: Object;\r\n\r\n\t/**\r\n\t * Names of geodata items, such as countries, to replace by from loaded\r\n\t * geodata.\r\n\t *\r\n\t * Can be used to override built-in English names for countries.\r\n\t *\r\n\t * ```TypeScript\r\n\t * import am4geodata_lang_ES from '@amcharts4-geodata/lang/es';\r\n\t * // ...\r\n\t * map.geodataNames = am4geodata_lang_ES;\r\n\t * ```\r\n\t * ```JavaScript\r\n\t * map.geodataNames = am4geodata_lang_ES;\r\n\t * ```\r\n\t * ```JSON\r\n\t * {\r\n\t * // ...\r\n\t * \"geodataNames\": am4geodata_lang_ES\r\n\t * }\r\n\t * ```\r\n\t *\r\n\t * @since 4.7.4\r\n\t */\r\n\tpublic geodataNames: { [index: string]: string };\r\n\r\n\t/**\r\n\t * A reference to a [[ZoomControl]] instance.\r\n\t */\r\n\tprotected _zoomControl: ZoomControl;\r\n\r\n\t/**\r\n\t * A reference to a [[SmallMap]] control instance.\r\n\t */\r\n\tprotected _smallMap: SmallMap;\r\n\r\n\t/**\r\n\t * [_zoomGeoPoint description]\r\n\t *\r\n\t * @todo Description\r\n\t */\r\n\tprotected _zoomGeoPoint: IGeoPoint;\r\n\r\n\t/**\r\n\t * Default duration of zoom animations (ms).\r\n\t */\r\n\tpublic zoomDuration: number = 1000;\r\n\r\n\t/**\r\n\t * Default zooming animation easing function.\r\n\t */\r\n\tpublic zoomEasing: (value: number) => number = $ease.cubicOut;\r\n\r\n\t/**\r\n\t * Smallest available zoom level. The map will not allow to zoom out past\r\n\t * this setting.\r\n\t *\r\n\t * NOTE: Should be power of 2.\r\n\t *\r\n\t * @default 1\r\n\t */\r\n\tpublic minZoomLevel: number = 1;\r\n\r\n\t/**\r\n\t * Biggest available zoom level. The map will not allow to zoom in past\r\n\t * this setting.\r\n\t *\r\n\t * NOTE: Should be power of 2.\r\n\t *\r\n\t * @default 32\r\n\t */\r\n\tpublic maxZoomLevel: number = 32;\r\n\r\n\t/**\r\n\t * [_prevZoomLevel description]\r\n\t *\r\n\t * @todo Description\r\n\t */\r\n\tprotected _prevZoomLevel: number;\r\n\r\n\t/**\r\n\t * [_prevZoomGeoPoint description]\r\n\t *\r\n\t * @todo Description\r\n\t */\r\n\tprotected _prevZoomGeoPoint: IGeoPoint = { latitude: 0, longitude: 0 };\r\n\r\n\t/**\r\n\t * Defines a type of series that this chart uses.\r\n\t */\r\n\tpublic _seriesType: MapSeries;\r\n\r\n\t/**\r\n\t * A reference to currently playing animation, e.g. zooming.\r\n\t */\r\n\tprotected _mapAnimation: Animation;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _mouseWheelDisposer: IDisposer;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic _zoomGeoPointReal: IGeoPoint;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _centerGeoPoint: IGeoPoint;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _fitWidth: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _fitHeight: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\r\n\tpublic panSprite: Circle;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _downPointOrig: IPoint;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _downDeltaLongitude: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _downDeltaLatitude: number;\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected _backgroundSeries: MapPolygonSeries;\r\n\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapChart\";\r\n\r\n\t\t// Set default projection\r\n\t\tthis.projection = new Projection();\r\n\r\n\t\tthis.setPropertyValue(\"deltaLatitude\", 0);\r\n\t\tthis.setPropertyValue(\"deltaLongitude\", 0);\r\n\t\tthis.setPropertyValue(\"deltaGamma\", 0);\r\n\t\tthis.maxPanOut = 0.7;\r\n\t\tthis.homeZoomLevel = 1;\r\n\t\tthis.zoomStep = 2;\r\n\t\tthis.layout = \"absolute\";\r\n\r\n\t\tthis.centerMapOnZoomOut = true;\r\n\r\n\t\t// Set padding\r\n\t\tthis.padding(0, 0, 0, 0);\r\n\r\n\t\t$utils.used(this.backgroundSeries);\r\n\r\n\t\t// so that the map would render in a hidden div too\r\n\t\tthis.minWidth = 10;\r\n\t\tthis.minHeight = 10;\r\n\r\n\t\tthis.events.once(\"inited\", this.handleAllInited, this, false);\r\n\r\n\t\t// Create a container for map series\r\n\t\tlet seriesContainer = this.seriesContainer;\r\n\t\tseriesContainer.visible = false;\r\n\t\tseriesContainer.inert = true;\r\n\t\tseriesContainer.resizable = true;\r\n\t\tseriesContainer.events.on(\"transformed\", this.handleMapTransform, this, false);\r\n\t\tseriesContainer.events.on(\"doublehit\", this.handleDoubleHit, this, false);\r\n\t\tseriesContainer.events.on(\"dragged\", this.handleDrag, this, false);\r\n\t\tseriesContainer.zIndex = 0;\r\n\t\tseriesContainer.dragWhileResize = true;\r\n\t\t//seriesContainer.background.fillOpacity = 0;\r\n\r\n\t\tseriesContainer.adapter.add(\"scale\", (scale, target) => {\r\n\t\t\treturn $math.fitToRange(scale, this.minZoomLevel, this.maxZoomLevel);\r\n\t\t});\r\n\r\n\t\t// Set up events\r\n\t\t//this.events.on(\"validated\", this.updateExtremes, this);\r\n\t\t//this.events.on(\"datavalidated\", this.handleAllValidated, this, false);\r\n\t\t//this.events.on(\"datavalidated\", this.updateExtremes, this, false);\r\n\r\n\t\tthis.events.on(\"maxsizechanged\", (event) => {\r\n\t\t\tif (event.previousWidth == 0 || event.previousHeight == 0) {\r\n\t\t\t\tthis.updateExtremes();\r\n\t\t\t\tthis.updateCenterGeoPoint();\r\n\t\t\t}\r\n\t\t}, undefined, false)\r\n\r\n\t\t// Set up main chart container, e.g. set backgrounds and events to monitor\r\n\t\t// size changes, etc.\r\n\t\tlet chartContainer = this.chartContainer;\r\n\t\tchartContainer.parent = this;\r\n\t\tchartContainer.zIndex = -1;\r\n\r\n\t\tthis._disposers.push(this.events.on(\"maxsizechanged\", () => {\r\n\t\t\tif (this.inited) {\r\n\t\t\t\tif (this._mapAnimation) {\r\n\t\t\t\t\tthis._mapAnimation.stop();\r\n\t\t\t\t}\r\n\r\n\t\t\t\tlet allInited = true;\r\n\t\t\t\tthis.series.each((series) => {\r\n\t\t\t\t\tseries.updateTooltipBounds();\r\n\t\t\t\t\tif (!series.inited || series.dataInvalid) {\r\n\t\t\t\t\t\tallInited = false;\r\n\t\t\t\t\t}\r\n\t\t\t\t})\r\n\t\t\t\tif (allInited) {\r\n\t\t\t\t\tthis.updateScaleRatio();\r\n\t\t\t\t}\r\n\t\t\t\tthis.zoomToGeoPoint(this._zoomGeoPointReal, this.zoomLevel, true, 0);\r\n\t\t\t}\r\n\r\n\t\t}, undefined, false));\r\n\r\n\t\tlet chartContainerBg = chartContainer.background;\r\n\t\tchartContainerBg.fillOpacity = 0;\r\n\t\tchartContainerBg.events.on(\"down\", (e) => { this.seriesContainer.dragStart(e.target.interactions.downPointers.getIndex(0)); }, this);\r\n\t\tchartContainerBg.events.on(\"up\", (e) => { this.seriesContainer.dragStop() }, this);\r\n\t\tchartContainerBg.events.on(\"doublehit\", this.handleDoubleHit, this);\r\n\t\tchartContainerBg.focusable = true;\r\n\r\n\t\tchartContainer.events.on(\"down\", this.handleMapDown, this, false);\r\n\r\n\t\tthis.addDisposer(seriesContainer.events.on(\"down\", () => {\r\n\t\t\t// Cancel any move inertia if there is one\r\n\t\t\tconst inertia = this.seriesContainer.interactions.inertias.getKey(\"move\");\r\n\t\t\tif (inertia) {\r\n\t\t\t\tinertia.done();\r\n\t\t\t}\r\n\t\t}))\r\n\r\n\t\t// Add description to background\r\n\t\tthis.background.fillOpacity = 0;\r\n\r\n\t\t// Add keyboard events for panning\r\n\t\tthis._disposers.push(getInteraction().body.events.on(\"keyup\", (ev) => {\r\n\t\t\tif (this.topParent.hasFocused) {\r\n\t\t\t\tconst key = keyboard.getEventKey(ev.event);\r\n\t\t\t\tif (!this._zoomControl || !this._zoomControl.thumb.isFocused) {\r\n\t\t\t\t\tswitch (key) {\r\n\t\t\t\t\t\tcase \"up\":\r\n\t\t\t\t\t\t\tthis.pan({ x: 0, y: 0.1 });\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"down\":\r\n\t\t\t\t\t\t\tthis.pan({ x: 0, y: -0.1 });\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"left\":\r\n\t\t\t\t\t\t\tthis.pan({ x: 0.1, y: 0 });\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"right\":\r\n\t\t\t\t\t\t\tthis.pan({ x: -0.1, y: 0 });\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}, this));\r\n\r\n\t\tthis.mouseWheelBehavior = \"zoom\";\r\n\r\n\t\tconst interaction = getInteraction();\r\n\t\tthis._disposers.push(interaction.body.events.on(\"down\", this.handlePanDown, this));\r\n\t\tthis._disposers.push(interaction.body.events.on(\"up\", this.handlePanUp, this));\r\n\t\t//this._disposers.push(interaction.body.events.on(\"track\", this.handlePanMove, this));\r\n\r\n\t\tlet panSprite = this.seriesContainer.createChild(Circle);\r\n\t\tpanSprite.radius = 10;\r\n\t\tpanSprite.inert = true;\r\n\t\tpanSprite.isMeasured = false;\r\n\t\tpanSprite.events.on(\"transformed\", this.handlePanMove, this, false);\r\n\t\tpanSprite.interactionsEnabled = false;\r\n\t\tpanSprite.opacity = 0;\r\n\t\tpanSprite.x = 0;\r\n\t\tpanSprite.y = 0;\r\n\t\tthis.panSprite = panSprite;\r\n\t\tthis.panBehavior = \"move\";\r\n\t\t/*\r\n\t\t\t\tthis.panSprite.inertiaOptions.setKey(\"move\", {\r\n\t\t\t\t\t\"time\": 100,\r\n\t\t\t\t\t\"duration\": 1000,\r\n\t\t\t\t\t\"factor\": 3,\r\n\t\t\t\t\t\"easing\": $ease.sinOut\r\n\t\t\t\t});*/\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected handlePanDown(event: IInteractionEvents[\"down\"]): void {\r\n\t\tlet svgPoint = $utils.documentPointToSvg(event.pointer.point, this.htmlContainer);\r\n\t\tif (svgPoint.x > 0 && svgPoint.y > 0 && svgPoint.x < this.svgContainer.width && svgPoint.y < this.svgContainer.height) {\r\n\t\t\t// Get local point\r\n\t\t\tthis._downPointOrig = $utils.documentPointToSprite(event.pointer.point, this.seriesContainer);\r\n\r\n\t\t\tthis.panSprite.moveTo(this._downPointOrig);\r\n\t\t\tthis.panSprite.dragStart(event.pointer);\r\n\t\t\tthis._downDeltaLongitude = this.deltaLongitude;\r\n\t\t\tthis._downDeltaLatitude = this.deltaLatitude;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected handlePanUp(event: IInteractionEvents[\"down\"]): void {\r\n\t\tif (this._downPointOrig) {\r\n\t\t\tthis.panSprite.dragStop(event.pointer, true);\r\n\t\t}\r\n\t\tthis._downPointOrig = undefined;\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected handlePanMove(): void {\r\n\r\n\t\tif (!this.seriesContainer.isResized) {\r\n\r\n\t\t\tif (getInteraction().areTransformed([this.panSprite.interactions, this.seriesContainer.interactions])) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tlet d3Projection = this.projection.d3Projection;\r\n\r\n\t\t\tlet panBehavior = this.panBehavior;\r\n\r\n\t\t\tif (panBehavior != \"move\" && panBehavior != \"none\" && this._downPointOrig && d3Projection.rotate) {\r\n\r\n\t\t\t\tlet rotation = d3Projection.rotate();\r\n\r\n\t\t\t\tlet dln = rotation[0];\r\n\t\t\t\tlet dlt = rotation[1];\r\n\t\t\t\tlet dlg = rotation[2];\r\n\r\n\t\t\t\td3Projection.rotate([0, 0, 0]);\r\n\r\n\t\t\t\tlet downGeoLocal = this.projection.invert(this._downPointOrig);\r\n\r\n\t\t\t\tlet local: IPoint = { x: this.panSprite.pixelX, y: this.panSprite.pixelY };\r\n\t\t\t\tlet geoLocal: IGeoPoint;\r\n\t\t\t\tif (local) {\r\n\t\t\t\t\tgeoLocal = this.projection.invert(local);\r\n\t\t\t\t}\r\n\r\n\t\t\t\td3Projection.rotate([dln, dlt, dlg]);\r\n\r\n\t\t\t\tif (geoLocal) {\r\n\t\t\t\t\tif (panBehavior == \"rotateLat\" || panBehavior == \"rotateLongLat\") {\r\n\t\t\t\t\t\tthis.deltaLatitude = this._downDeltaLatitude + geoLocal.latitude - downGeoLocal.latitude;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (panBehavior == \"rotateLong\" || panBehavior == \"rotateLongLat\") {\r\n\t\t\t\t\t\tthis.deltaLongitude = this._downDeltaLongitude + geoLocal.longitude - downGeoLocal.longitude;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected handleAllInited() {\r\n\t\tlet inited = true;\r\n\t\tthis.seriesContainer.visible = true;\r\n\t\tthis.series.each((series) => {\r\n\t\t\tif (!series.inited || series.dataInvalid) {\r\n\t\t\t\tinited = false;\r\n\t\t\t}\r\n\t\t})\r\n\t\tif (inited) {\r\n\t\t\tthis.updateCenterGeoPoint();\r\n\t\t\tthis.updateScaleRatio();\r\n\t\t\tthis.goHome(0);\r\n\t\t}\r\n\t\telse {\r\n\t\t\t// TODO verify that this is correct\r\n\t\t\tconst disposer = registry.events.once(\"exitframe\", () => {\r\n\t\t\t\tthis.removeDispose(disposer);\r\n\t\t\t\tthis.handleAllInited();\r\n\t\t\t}, this, false);\r\n\r\n\t\t\tthis.addDisposer(disposer);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic updateZoomGeoPoint() {\r\n\t\tlet seriesPoint = $utils.svgPointToSprite({ x: this.innerWidth / 2 + this.pixelPaddingLeft, y: this.innerHeight / 2 + this.pixelPaddingTop }, this.series.getIndex(0));\r\n\t\tlet geoPoint = this.projection.invert(seriesPoint);\r\n\t\tthis._zoomGeoPointReal = geoPoint;\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tpublic updateCenterGeoPoint() {\r\n\t\tlet maxLeft: number;\r\n\t\tlet maxRight: number;\r\n\t\tlet maxTop: number;\r\n\t\tlet maxBottom: number;\r\n\r\n\r\n\t\tif (this.backgroundSeries) {\r\n\t\t\tlet features = this.backgroundSeries.getFeatures();\r\n\t\t\tif (features.length > 0) {\r\n\t\t\t\tlet bounds = this.projection.d3Path.bounds(features[0].geometry);\r\n\t\t\t\tmaxLeft = bounds[0][0];\r\n\t\t\t\tmaxTop = bounds[0][1];\r\n\t\t\t\tmaxRight = bounds[1][0];\r\n\t\t\t\tmaxBottom = bounds[1][1];\r\n\t\t\t}\r\n\t\t}\r\n\t\telse {\r\n\t\t\tthis.series.each((series) => {\r\n\t\t\t\tlet bbox = series.group.node.getBBox();\r\n\r\n\t\t\t\tif (maxLeft > bbox.x || !$type.isNumber(maxLeft)) {\r\n\t\t\t\t\tmaxLeft = bbox.x;\r\n\t\t\t\t}\r\n\t\t\t\tif (maxRight < bbox.x + bbox.width || !$type.isNumber(maxRight)) {\r\n\t\t\t\t\tmaxRight = bbox.x + bbox.width;\r\n\t\t\t\t}\r\n\t\t\t\tif (maxTop > bbox.y || !$type.isNumber(maxTop)) {\r\n\t\t\t\t\tmaxTop = bbox.y;\r\n\t\t\t\t}\r\n\t\t\t\tif (maxBottom < bbox.y + bbox.height || !$type.isNumber(maxBottom)) {\r\n\t\t\t\t\tmaxBottom = bbox.y + bbox.height;\r\n\t\t\t\t}\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tthis.seriesMaxLeft = maxLeft;\r\n\t\tthis.seriesMaxRight = maxRight;\r\n\t\tthis.seriesMaxTop = maxTop;\r\n\t\tthis.seriesMaxBottom = maxBottom;\r\n\r\n\t\tthis.seriesWidth = maxRight - maxLeft;\r\n\t\tthis.seriesHeight = maxBottom - maxTop;\r\n\r\n\t\tif (this.seriesWidth > 0 && this.seriesHeight > 0) {\r\n\t\t\tthis.chartContainer.visible = true;\r\n\t\t\tthis._centerGeoPoint = this.projection.invert({ x: maxLeft + (maxRight - maxLeft) / 2, y: maxTop + (maxBottom - maxTop) / 2 });\r\n\r\n\t\t\tif (!this._zoomGeoPointReal || !$type.isNumber(this._zoomGeoPointReal.latitude)) {\r\n\t\t\t\tthis._zoomGeoPointReal = this._centerGeoPoint;\r\n\t\t\t}\r\n\t\t}\r\n\t\telse {\r\n\t\t\tthis.chartContainer.visible = false;\r\n\t\t}\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * Prevents map to be dragged out of the container area\r\n\t * @ignore\r\n\t */\r\n\tprotected handleDrag() {\r\n\r\n\t\tlet d = this.zoomLevel * this.scaleRatio;\r\n\r\n\t\tlet ww = this.seriesWidth * d;\r\n\t\tlet hh = this.seriesHeight * d;\r\n\r\n\t\tlet seriesContainer = this.seriesContainer;\r\n\t\tlet maxLeft = this.seriesMaxLeft * d;\r\n\t\tlet maxRight = this.seriesMaxRight * d;\r\n\t\tlet maxTop = this.seriesMaxTop * d;\r\n\t\tlet maxBottom = this.seriesMaxBottom * d;\r\n\r\n\t\tlet x = seriesContainer.pixelX;\r\n\t\tlet y = seriesContainer.pixelY;\r\n\r\n\t\tlet maxPanOut = this.maxPanOut;\r\n\r\n\t\tlet minX = Math.min(this.maxWidth * (1 - maxPanOut) - ww - maxLeft, -maxLeft);\r\n\t\tif (x < minX) {\r\n\t\t\tx = minX;\r\n\t\t}\r\n\r\n\t\tlet maxX = Math.max(this.maxWidth * maxPanOut - maxLeft, this.maxWidth - maxRight);\r\n\t\tif (x > maxX) {\r\n\t\t\tx = maxX;\r\n\t\t}\r\n\r\n\t\tlet minY = Math.min(this.maxHeight * (1 - maxPanOut) - hh - maxTop, -maxTop)\r\n\t\tif (y < minY) {\r\n\t\t\ty = minY;\r\n\t\t}\r\n\r\n\t\tlet maxY = Math.max(this.maxHeight * maxPanOut - maxTop, this.maxHeight - maxBottom);\r\n\t\tif (y > maxY) {\r\n\t\t\ty = maxY;\r\n\t\t}\r\n\r\n\t\tseriesContainer.moveTo({ x: x, y: y }, undefined, undefined, true);\r\n\r\n\t\tthis._zoomGeoPointReal = this.zoomGeoPoint;\r\n\t}\r\n\r\n\t/**\r\n\t * Sets defaults that instantiate some objects that rely on parent, so they\r\n\t * cannot be set in constructor.\r\n\t */\r\n\tprotected applyInternalDefaults(): void {\r\n\r\n\t\tsuper.applyInternalDefaults();\r\n\r\n\t\t// Add a default screen reader title for accessibility\r\n\t\t// This will be overridden in screen reader if there are any `titles` set\r\n\t\tif (!$type.hasValue(this.readerTitle)) {\r\n\t\t\tthis.readerTitle = this.language.translate(\"Map\");\r\n\t\t}\r\n\r\n\t\tif (!$type.hasValue(this.background.readerTitle)) {\r\n\t\t\tthis.background.readerTitle = this.language.translate(\"Use plus and minus keys on your keyboard to zoom in and out\");\r\n\t\t}\r\n\r\n\t}\r\n\r\n\t/**\r\n\t * Handles event when a pointer presses down on the map, e.g. user presses\r\n\t * down mouse or touches the map on a screen.\r\n\t *\r\n\t * Stops all animations currently going on.\r\n\t */\r\n\tprotected handleMapDown(): void {\r\n\t\tif (this._mapAnimation) {\r\n\t\t\tthis._mapAnimation.stop();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Handles the event when user doubleclicks or dooubletaps the map: zooms\r\n\t * in on the reference point.\r\n\t *\r\n\t * @param event Original event\r\n\t */\r\n\tprotected handleDoubleHit(event: AMEvent[\"doublehit\"]) {\r\n\t\tlet svgPoint: IPoint = $utils.documentPointToSvg(event.point, this.htmlContainer, this.svgContainer.cssScale);\r\n\t\tlet geoPoint: IGeoPoint = this.svgPointToGeo(svgPoint);\r\n\t\tthis.zoomIn(geoPoint);\r\n\t}\r\n\r\n\t/**\r\n\t * Handles mouse wheel event, e.g. user rotates mouse wheel while over the\r\n\t * map: zooms in or out depending on the direction of the wheel turn.\r\n\t *\r\n\t * @param event Original event\r\n\t */\r\n\tprotected handleWheel(event: AMEvent[\"wheel\"]) {\r\n\r\n\t\t// Cancel any move inertia if there is one\r\n\t\tconst inertia = this.seriesContainer.interactions.inertias.getKey(\"move\");\r\n\t\tif (inertia) {\r\n\t\t\tinertia.done();\r\n\t\t}\r\n\r\n\t\tlet svgPoint: IPoint = $utils.documentPointToSvg(event.point, this.htmlContainer, this.svgContainer.cssScale);\r\n\t\tlet geoPoint: IGeoPoint = this.svgPointToGeo(svgPoint);\r\n\r\n\t\tif (event.shift.y < 0) {\r\n\t\t\tthis.zoomIn(geoPoint, undefined, this.interactions.mouseOptions.sensitivity);\r\n\t\t}\r\n\t\telse {\r\n\t\t\tthis.zoomOut(geoPoint, undefined, this.interactions.mouseOptions.sensitivity);\r\n\t\t}\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Specifies what should chart do if when mouse wheel is rotated.\r\n\t *\r\n\t * @see {@link https://www.amcharts.com/docs/v4/reference/sprite/#mouseOptions_property} More information about `mouseOptions`\r\n\t * @param mouse wheel behavior\r\n\t * @default zoomX\r\n\t */\r\n\tpublic set mouseWheelBehavior(value: \"zoom\" | \"none\") {\r\n\r\n\t\tif (this.setPropertyValue(\"mouseWheelBehavior\", value)) {\r\n\t\t\tif (value != \"none\") {\r\n\t\t\t\tthis._mouseWheelDisposer = this.chartContainer.events.on(\"wheel\", this.handleWheel, this, false);\r\n\t\t\t\tthis._disposers.push(this._mouseWheelDisposer);\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tif (this._mouseWheelDisposer) {\r\n\t\t\t\t\tthis._mouseWheelDisposer.dispose();\r\n\t\t\t\t}\r\n\t\t\t\tthis.chartContainer.wheelable = false;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return mouse wheel behavior\r\n\t */\r\n\tpublic get mouseWheelBehavior(): \"zoom\" | \"none\" {\r\n\t\treturn this.getPropertyValue(\"mouseWheelBehavior\");\r\n\t}\r\n\r\n\t/**\r\n\t * What \"dragging\" map does.\r\n\t *\r\n\t * Available values:\r\n\t * * `\"move\"` (default): changes position of the map.\r\n\t * * `\"rotateLat\"`: changes `deltaLatitude` (rotates the globe vertically).\r\n\t * * `\"rotateLong\"`: changes `deltaLongitude` (rotates the globe horizontally).\r\n\t * * `\"rotateLongLat\"`: changes both `deltaLongitude` and `deltaLatitude` (rotates the globe in any direction).\r\n\t *\r\n\t * @default \"move\"\r\n\t * @since 4.3.0\r\n\t * @param value Behavior\r\n\t */\r\n\tpublic set panBehavior(value: \"none\" | \"move\" | \"rotateLat\" | \"rotateLong\" | \"rotateLongLat\") {\r\n\t\tif (this.setPropertyValue(\"panBehavior\", value)) {\r\n\t\t\tlet seriesContainer = this.seriesContainer;\r\n\t\t\tthis.panSprite.draggable = false;\r\n\t\t\tseriesContainer.draggable = false;\r\n\r\n\t\t\tswitch (value) {\r\n\t\t\t\tcase \"move\":\r\n\t\t\t\t\tseriesContainer.draggable = true;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tdefault:\r\n\t\t\t\t\tthis.panSprite.draggable = true;\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @returns If the map should be centered when zooming out.\r\n\t */\r\n\tpublic get centerMapOnZoomOut(): boolean {\r\n\t\treturn this.getPropertyValue(\"centerMapOnZoomOut\");\r\n\t}\r\n\r\n\t/**\r\n\t * Specifies if the map should be centered when zooming out\r\n\t * @default true\r\n\t * @since 4.7.12\r\n\t */\r\n\tpublic set centerMapOnZoomOut(value: boolean) {\r\n\t\tthis.setPropertyValue(\"centerMapOnZoomOut\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @returns Behavior\r\n\t */\r\n\tpublic get panBehavior(): \"none\" | \"move\" | \"rotateLat\" | \"rotateLong\" | \"rotateLongLat\" {\r\n\t\treturn this.getPropertyValue(\"panBehavior\");\r\n\t}\r\n\r\n\t/**\r\n\t * Projection to use for the map.\r\n\t *\r\n\t * Available projections:\r\n\t * * Albers\r\n\t * * AlbersUSA\r\n\t * * AzimuthalEqualArea\r\n\t * * Eckert6\r\n\t * * EqualEarth\r\n\t * * Mercator\r\n\t * * Miller\r\n\t * * NaturalEarth\r\n\t * * Orthographic\r\n\t * * Stereographic\r\n\t *\r\n\t * ```TypeScript\r\n\t * map.projection = new am4maps.projections.Mercator();\r\n\t * ```\r\n\t * ```JavaScript\r\n\t * map.projection = new am4maps.projections.Mercator();\r\n\t * ```\r\n\t * ```JSON\r\n\t * {\r\n\t * // ...\r\n\t * \"projection\": \"Mercator\"\r\n\t * // ...\r\n\t * }\r\n\t * ```\r\n\t *\r\n\t * @see {@link https://www.amcharts.com/docs/v4/chart-types/map/#Setting_projection} More about projections\r\n\t * @param projection Projection\r\n\t */\r\n\tpublic set projection(projection: Projection) {\r\n\t\tif (this.setPropertyValue(\"projection\", projection)) {\r\n\t\t\tthis.invalidateProjection();\r\n\r\n\t\t\tprojection.chart = this;\r\n\r\n\t\t\tif (this._backgroundSeries) {\r\n\t\t\t\tthis._backgroundSeries.invalidate();\r\n\t\t\t}\r\n\r\n\t\t\tif (this.inited) {\r\n\t\t\t\tthis.updateExtremes();\r\n\t\t\t}\r\n\r\n\t\t\tthis.series.each((series) => {\r\n\t\t\t\tseries.events.once(\"validated\", () => {\r\n\t\t\t\t\tthis.updateCenterGeoPoint();\r\n\t\t\t\t\tthis.updateScaleRatio();\r\n\t\t\t\t\tthis.goHome(0);\r\n\t\t\t\t});\r\n\t\t\t})\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Projection\r\n\t */\r\n\tpublic get projection(): Projection {\r\n\t\treturn this.getPropertyValue(\"projection\");\r\n\t}\r\n\r\n\t/**\r\n\t * Validates (processes) data items.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic validateDataItems() {\r\n\t\tsuper.validateDataItems();\r\n\t\tthis.updateExtremes();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Calculates the longitudes and latitudes of the most distant points from\r\n\t * the center in all four directions: West, East, North, and South.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic updateExtremes(): void {\r\n\r\n\t\tlet east: number;\r\n\t\tlet north: number;\r\n\t\tlet west: number;\r\n\t\tlet south: number;\r\n\r\n\t\tthis.series.each((series) => {\r\n\t\t\tif (series.ignoreBounds || (series instanceof GraticuleSeries && series.fitExtent)) {\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tif (series.north > north || !$type.isNumber(north)) {\r\n\t\t\t\t\tnorth = series.north;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (series.south < south || !$type.isNumber(south)) {\r\n\t\t\t\t\tsouth = series.south;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (series.west < west || !$type.isNumber(west)) {\r\n\t\t\t\t\twest = series.west;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (series.east > east || !$type.isNumber(east)) {\r\n\t\t\t\t\teast = series.east;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\tlet features: any[] = [];\r\n\t\tlet foundGraticule = false;\r\n\t\t// if we gave graticule, get features of these series only for faster fitSize\r\n\t\tthis.series.each((series) => {\r\n\t\t\tif (series instanceof GraticuleSeries && !series.fitExtent) {\r\n\t\t\t\tfeatures = series.getFeatures();\r\n\t\t\t\tfoundGraticule = true;\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\tif (!foundGraticule) {\r\n\t\t\tthis.series.each((series) => {\r\n\t\t\t\tif (series.ignoreBounds || (series instanceof GraticuleSeries && series.fitExtent)) {\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tfeatures = features.concat(series.getFeatures());\r\n\t\t\t\t}\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tlet w = $math.max(50, this.innerWidth);\r\n\t\tlet h = $math.max(50, this.innerHeight);\r\n\r\n\t\tlet d3Projection = this.projection.d3Projection;\r\n\r\n\t\tif (features.length > 0 && d3Projection && (this.east != east || this.west != west || this.north != north || this.south != south)) {\r\n\t\t\tthis.east = east;\r\n\t\t\tthis.west = west;\r\n\t\t\tthis.north = north;\r\n\t\t\tthis.south = south;\r\n\t\t\tif (d3Projection.rotate) {\r\n\t\t\t\tlet rotation = d3Projection.rotate();\r\n\t\t\t\tlet deltaLong = rotation[0];\r\n\t\t\t\tlet deltaLat = rotation[1];\r\n\t\t\t\tlet deltaGamma = rotation[2];\r\n\r\n\t\t\t\tthis.deltaLongitude = deltaLong;\r\n\t\t\t\tthis.deltaLatitude = deltaLat;\r\n\t\t\t\tthis.deltaGamma = deltaGamma;\r\n\t\t\t}\r\n\r\n\t\t\tlet geoJSON = { \"type\": \"FeatureCollection\", features: features };\r\n\r\n\t\t\tlet initialScale = d3Projection.scale();\r\n\r\n\t\t\td3Projection.fitSize([w, h], geoJSON);\r\n\r\n\t\t\tif (d3Projection.scale() != initialScale) {\r\n\t\t\t\tthis.invalidateDataUsers();\r\n\t\t\t}\r\n\r\n\t\t\tthis.series.each((series) => {\r\n\t\t\t\tif (series instanceof GraticuleSeries) {\r\n\t\t\t\t\tseries.invalidateData();\r\n\t\t\t\t}\r\n\t\t\t})\r\n\r\n\t\t\tif (this._backgroundSeries) {\r\n\t\t\t\tlet polygon = this._backgroundSeries.mapPolygons.getIndex(0);\r\n\t\t\t\tif (polygon) {\r\n\t\t\t\t\tpolygon.multiPolygon = $mapUtils.getBackground(this.north, this.east, this.south, this.west);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tthis._fitWidth = w;\r\n\t\t\tthis._fitHeight = h;\r\n\t\t}\r\n\r\n\t\tif (!this._zoomGeoPointReal || !$type.isNumber(this._zoomGeoPointReal.latitude)) {\r\n\t\t\tthis.goHome(0);\r\n\t\t}\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * (Re)calculates a ratio which should be used to scale the actual map so\r\n\t * that it fits perfectly into available space. Helps to avoid redrawing of all the map if container size changes\r\n\t * @ignore\r\n\t */\r\n\tprotected updateScaleRatio(): void {\r\n\t\tlet scaleRatio: number;\r\n\r\n\t\tthis.updateCenterGeoPoint();\r\n\r\n\t\tlet hScale: number = this.innerWidth / this.seriesWidth;\r\n\t\tlet vScale: number = this.innerHeight / this.seriesHeight;\r\n\r\n\t\tscaleRatio = $math.min(hScale, vScale);\r\n\r\n\t\tif ($type.isNaN(scaleRatio) || scaleRatio == Infinity) {\r\n\t\t\tscaleRatio = 1;\r\n\t\t}\r\n\r\n\t\tif (scaleRatio != this.scaleRatio) {\r\n\t\t\tthis.scaleRatio = scaleRatio;\r\n\r\n\t\t\t$iter.each(this.series.iterator(), (series) => {\r\n\t\t\t\tseries.scale = scaleRatio;\r\n\t\t\t\tseries.updateTooltipBounds();\r\n\t\t\t});\r\n\r\n\t\t\tthis.backgroundSeries.scale = scaleRatio;\r\n\r\n\t\t\tthis.dispatch(\"scaleratiochanged\");\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Converts a point within map container to geographical (lat/long)\r\n\t * coordinates.\r\n\t *\r\n\t * @param point Source point\r\n\t * @return Geo-point\r\n\t */\r\n\tpublic svgPointToGeo(point: IPoint): IGeoPoint {\r\n\t\tlet series: MapSeries = this.series.getIndex(0);\r\n\t\tif (series) {\r\n\t\t\tlet seriesPoint: IPoint = $utils.svgPointToSprite(point, series);\r\n\t\t\treturn this.seriesPointToGeo(seriesPoint);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Converts geographical (lat/long) coordinates to an X/Y point within map's\r\n\t * container.\r\n\t *\r\n\t * @param point Source geo-point\r\n\t * @return Point\r\n\t */\r\n\tpublic geoPointToSVG(point: IGeoPoint): IPoint {\r\n\t\tlet series: MapSeries = this.series.getIndex(0);\r\n\t\tif (series) {\r\n\t\t\tlet seriesPoint: IPoint = this.geoPointToSeries(point);\r\n\t\t\treturn $utils.spritePointToSvg(seriesPoint, series);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Converts a point (X/Y) within actual objects of the map to geographical\r\n\t * (lat/long) coordinates.\r\n\t *\r\n\t * @param point Source point\r\n\t * @return Geo-point\r\n\t */\r\n\tpublic seriesPointToGeo(point: IPoint): IGeoPoint {\r\n\t\treturn this.projection.invert(point);\r\n\t}\r\n\r\n\t/**\r\n\t * Converts geographical (lat/long) coordinates to an X/Y point within\r\n\t * actual elements/objects of the maps.\r\n\t *\r\n\t * @param point Source geo-point\r\n\t * @return Point\r\n\t */\r\n\tpublic geoPointToSeries(point: IGeoPoint): IPoint {\r\n\t\treturn this.projection.convert(point);\r\n\t}\r\n\r\n\t/**\r\n\t * Map data in GeoJSON format.\r\n\t *\r\n\t * The Map supports the following GeoJSON objects: `Point`, `LineString`,\r\n\t * `Polygon`, `MultiPoint`, `MultiLineString`, and `MultiPolygon`.\r\n\t *\r\n\t * @see {@link http://geojson.org/} Official GeoJSON format specification\r\n\t * @param geoJSON GeoJSON data\r\n\t */\r\n\tpublic set geodata(geodata: Object) {\r\n\t\tif (geodata != this._geodata) {\r\n\t\t\tthis._geodata = geodata;\r\n\r\n\t\t\tif (this.reverseGeodata) {\r\n\t\t\t\tthis.processReverseGeodata(this._geodata);\r\n\t\t\t}\r\n\t\t\tthis.invalidateData();\r\n\r\n\t\t\tthis.dataUsers.each((dataUser) => {\r\n\t\t\t\tfor (let i = dataUser.data.length - 1; i >= 0; i--) {\r\n\t\t\t\t\tif (dataUser.data[i].madeFromGeoData == true) {\r\n\t\t\t\t\t\tdataUser.data.splice(i, 1);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tdataUser.disposeData();\r\n\t\t\t\tdataUser.invalidateData();\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return GeoJSON data\r\n\t */\r\n\tpublic get geodata(): Object {\r\n\t\treturn this._geodata;\r\n\t}\r\n\r\n\t/**\r\n\t * Indicates whether GeoJSON geodata supplied to the chart uses\r\n\t * ESRI (clockwise) or non-ESRI (counter-clockwise) order of the polygon\r\n\t * coordinates.\r\n\t *\r\n\t * `MapChart` supports only ESRI standard, so if your custom maps appears\r\n\t * garbled, try setting `reverseGeodata = true`.\r\n\t * \r\n\t * @default false\r\n\t * @since 4.10.11\r\n\t * @param value Reverse the order of geodata coordinates?\r\n\t */\r\n\tpublic set reverseGeodata(value: boolean) {\r\n\t\tif (this.setPropertyValue(\"reverseGeodata\", value) && this._geodata) {\r\n\t\t\tthis.processReverseGeodata(this._geodata);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @returns Reverse the order of geodata coordinates?\r\n\t */\r\n\tpublic get reverseGeodata(): boolean {\r\n\t\treturn this.getPropertyValue(\"reverseGeodata\");\r\n\t}\r\n\r\n\t/**\r\n\t * Reverses the order of polygons on a GeoJSON data.\r\n\t *\r\n\t * @since 4.10.11\r\n\t * @param geodata Source geodata\r\n\t */\r\n\tpublic processReverseGeodata(geodata: any): void {\r\n\t\tfor (let i = 0; i < geodata.features.length; i++) {\r\n\t\t\tlet feature = geodata.features[i];\r\n\t\t\tfor (let x = 0; x < feature.geometry.coordinates.length; x++) {\r\n\t\t\t\tif (feature.geometry.type == \"MultiPolygon\") {\r\n\t\t\t\t\tfor (let y = 0; y < feature.geometry.coordinates[x].length; y++) {\r\n\t\t\t\t\t\tfeature.geometry.coordinates[x][y].reverse()\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tfeature.geometry.coordinates[x].reverse()\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Zooms the map to particular zoom level and centers on a latitude/longitude\r\n\t * coordinate.\r\n\t *\r\n\t * @param point Center coordinate\r\n\t * @param zoomLevel Zoom level\r\n\t * @param center Center on the given coordinate?\r\n\t * @param duration Duration for zoom animation (ms)\r\n\t * @return Zoom animation\r\n\t */\r\n\tpublic zoomToGeoPoint(point: IGeoPoint, zoomLevel: number, center?: boolean, duration?: number, mapObject?: boolean): Animation {\r\n\r\n\t\tif (!point) {\r\n\t\t\tlet hasData = false;\r\n\t\t\tthis.series.each((series) => {\r\n\t\t\t\tif (series.dataItems.length > 0) {\r\n\t\t\t\t\thasData = true;\r\n\t\t\t\t}\r\n\t\t\t})\r\n\t\t\tif (hasData) {\r\n\t\t\t\tpoint = this.zoomGeoPoint;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif (!point || !$type.isNumber(point.longitude) || !$type.isNumber(point.latitude)) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tthis._zoomGeoPointReal = point;\r\n\r\n\t\tzoomLevel = $math.fitToRange(zoomLevel, this.minZoomLevel, this.maxZoomLevel);\r\n\r\n\t\tlet seriesPoint: IPoint = this.projection.convert(point);\r\n\t\tif (seriesPoint) {\r\n\r\n\t\t\tlet svgPoint: IPoint = this.geoPointToSVG(point);\r\n\r\n\t\t\tlet mapPoint = $utils.svgPointToSprite(svgPoint, this);\r\n\r\n\t\t\tif (center) {\r\n\t\t\t\tmapPoint = {\r\n\t\t\t\t\tx: this.innerWidth / 2,\r\n\t\t\t\t\ty: this.innerHeight / 2\r\n\t\t\t\t};\r\n\t\t\t}\r\n\r\n\t\t\tif (!$type.isNumber(duration)) {\r\n\t\t\t\tduration = this.zoomDuration;\r\n\t\t\t}\r\n\r\n\t\t\tlet x = mapPoint.x - seriesPoint.x * zoomLevel * this.scaleRatio;\r\n\t\t\tlet y = mapPoint.y - seriesPoint.y * zoomLevel * this.scaleRatio;\r\n\r\n\r\n\t\t\tif (!mapObject && zoomLevel < this.zoomLevel && this.centerMapOnZoomOut && zoomLevel < 1.5) {\r\n\t\t\t\tx = this.innerWidth / 2 - (this.seriesMaxLeft + (this.seriesMaxRight - this.seriesMaxLeft) / 2) * zoomLevel * this.scaleRatio;\r\n\t\t\t\ty = this.innerHeight / 2 - (this.seriesMaxTop + (this.seriesMaxBottom - this.seriesMaxTop) / 2) * zoomLevel * this.scaleRatio;\r\n\t\t\t}\r\n\r\n\t\t\tthis._mapAnimation = this.seriesContainer.animate(\r\n\t\t\t\t[{\r\n\t\t\t\t\tproperty: \"scale\",\r\n\t\t\t\t\tto: zoomLevel\r\n\t\t\t\t}, {\r\n\t\t\t\t\tproperty: \"x\", from: this.seriesContainer.pixelX,\r\n\t\t\t\t\tto: x\r\n\t\t\t\t}, {\r\n\t\t\t\t\tproperty: \"y\", from: this.seriesContainer.pixelY,\r\n\t\t\t\t\tto: y\r\n\t\t\t\t}], duration, this.zoomEasing);\r\n\r\n\t\t\tthis._disposers.push(this._mapAnimation.events.on(\"animationended\", () => {\r\n\t\t\t\tthis._zoomGeoPointReal = this.zoomGeoPoint;\r\n\t\t\t}))\r\n\r\n\r\n\t\t\tthis.seriesContainer.validatePosition();\r\n\r\n\t\t\treturn this._mapAnimation;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Zooms the map to a particular map object.\r\n\t *\r\n\t * @param mapObject Target map object\r\n\t * @param zoomLevel Zoom level\r\n\t * @param center Center on the given coordinate?\r\n\t * @param duration Duration for zoom animation (ms)\r\n\t * @return Zoom animation\r\n\t */\r\n\tpublic zoomToMapObject(mapObject: MapObject, zoomLevel?: number, center?: boolean, duration?: number): Animation {\r\n\t\tif (center == undefined) {\r\n\t\t\tcenter = true;\r\n\t\t}\r\n\r\n\t\tconst inertia = this.seriesContainer.interactions.inertias.getKey(\"move\");\r\n\t\tif (inertia) {\r\n\t\t\tinertia.done();\r\n\t\t}\r\n\r\n\t\tif (mapObject instanceof MapImage) {\r\n\t\t\tif ($type.isNaN(zoomLevel)) {\r\n\t\t\t\tzoomLevel = 5;\r\n\t\t\t}\r\n\t\t\treturn this.zoomToGeoPoint({ latitude: mapObject.latitude, longitude: mapObject.longitude }, zoomLevel, center, duration, true);\r\n\t\t}\r\n\r\n\t\tlet dataItem = mapObject.dataItem;\r\n\r\n\t\tif (dataItem && $type.isNumber(dataItem.zoomLevel)) {\r\n\t\t\tzoomLevel = dataItem.zoomLevel;\r\n\t\t}\r\n\r\n\r\n\t\tif (mapObject instanceof MapPolygon) {\r\n\t\t\tlet dataItem = mapObject.dataItem;\r\n\t\t\tlet bbox = mapObject.polygon.bbox;\r\n\t\t\tif (bbox.width == 0 || bbox.height == 0) {\r\n\t\t\t\tbbox = mapObject.polygon.group.getBBox();\r\n\t\t\t}\r\n\r\n\t\t\tif (!$type.isNumber(zoomLevel)) {\r\n\t\t\t\tzoomLevel = Math.min(this.seriesWidth / bbox.width, this.seriesHeight / bbox.height);\r\n\t\t\t}\r\n\r\n\t\t\tlet geoPoint: IGeoPoint;\r\n\r\n\t\t\tif (dataItem && $type.hasValue(dataItem.zoomGeoPoint)) {\r\n\t\t\t\tgeoPoint = dataItem.zoomGeoPoint;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t// this is more accurate\r\n\t\t\t\tlet polygonPoint = { x: bbox.x + bbox.width / 2, y: bbox.y + bbox.height / 2 };\r\n\t\t\t\tlet seriesPoint = $utils.spritePointToSprite(polygonPoint, mapObject.polygon, mapObject.series);\r\n\r\n\t\t\t\tgeoPoint = this.seriesPointToGeo(seriesPoint);\r\n\t\t\t}\r\n\r\n\t\t\treturn this.zoomToGeoPoint(geoPoint, zoomLevel, true, duration, true);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Zooms the map to a particular viewport.\r\n\t *\r\n\t * The `north`, `east`, `south`, and `west` define boundaries of the\r\n\t * imaginary viewort we want to zoom the map to.\r\n\t *\r\n\t * `level` is not actual zoom level. The map will determine the zoom level\r\n\t * required to accommodated such zoom, and will adjust it by `level` if set.\r\n\t *\r\n\t * @param north Latitude of the North-most boundary\r\n\t * @param east Longitude of the East-most boundary\r\n\t * @param south Latitude of the South-most boundary\r\n\t * @param west Longitude of the West-most boundary\r\n\t * @param level Adjust zoom level\r\n\t * @param center Center on the given coordinate?\r\n\t * @param duration Duration for zoom animation (ms)\r\n\t * @return Zoom animation\r\n\t */\r\n\tpublic zoomToRectangle(north: number, east: number, south: number, west: number, level?: number, center?: boolean, duration?: number): Animation {\r\n\t\tif ($type.isNaN(level)) {\r\n\t\t\tlevel = 1;\r\n\t\t}\r\n\r\n\t\tlet w = $math.min(west, east);\r\n\t\tlet e = $math.max(west, east);\r\n\r\n\t\twest = w;\r\n\t\teast = e;\r\n\r\n\t\tlet splitLongitude = $math.normalizeAngle(180 - this.deltaLongitude);\r\n\t\tif (splitLongitude > 180) {\r\n\t\t\tsplitLongitude -= 360;\r\n\t\t}\r\n\r\n\t\tlet newLong = west + (east - west) / 2;\r\n\t\tlet d = (west - east);\r\n\r\n\t\tif (west < splitLongitude && east > splitLongitude) {\r\n\t\t\tnewLong += 180;\r\n\t\t\td = $math.normalizeAngle(east - west - 360);\r\n\t\t}\r\n\r\n\t\tlet zoomLevel = level * Math.min((this.south - this.north) / (south - north), Math.abs((this.west - this.east) / d));\r\n\r\n\t\treturn this.zoomToGeoPoint({ latitude: north + (south - north) / 2, longitude: newLong }, zoomLevel, center, duration, true);\r\n\t}\r\n\r\n\t/**\r\n\t * Zooms in the map, optionally centering on particular latitude/longitude\r\n\t * point.\r\n\t *\r\n\t * @param geoPoint Optional center point\r\n\t * @param duration Duration for zoom animation (ms)\r\n\t * @return Zoom animation\r\n\t */\r\n\tpublic zoomIn(geoPoint?: IGeoPoint, duration?: number, sensitivity: number = 1): Animation {\r\n\t\tlet step = 1 + (this.zoomStep - 1) * sensitivity;\r\n\t\tif (step < 1) {\r\n\t\t\tstep = 1;\r\n\t\t}\r\n\t\treturn this.zoomToGeoPoint(geoPoint, this.zoomLevel * step, false, duration);\r\n\t}\r\n\r\n\t/**\r\n\t * Zooms out the map, optionally centering on particular latitude/longitude\r\n\t * point.\r\n\t *\r\n\t * @param geoPoint Optional center point\r\n\t * @param duration Duration for zoom animation (ms)\r\n\t * @return Zoom animation\r\n\t */\r\n\tpublic zoomOut(geoPoint?: IGeoPoint, duration?: number, sensitivity: number = 1): Animation {\r\n\t\tlet step = 1 + (this.zoomStep - 1) * sensitivity;\r\n\t\tif (step < 1) {\r\n\t\t\tstep = 1;\r\n\t\t}\r\n\t\treturn this.zoomToGeoPoint(geoPoint, this.zoomLevel / step, false, duration);\r\n\t}\r\n\r\n\t/**\r\n\t * Pans the maps using relative coordinates. E.g.:\r\n\t *\r\n\t * ```JSON\r\n\t * {\r\n\t * x: 0.1,\r\n\t * y: -0.1\r\n\t * }\r\n\t * ```\r\n\t *\r\n\t * The above will move the map by 10% to the right, and by 10% upwards.\r\n\t *\r\n\t * @param shift Vertical and horizontal shift\r\n\t * @param duration Pan animation duration (ms)\r\n\t */\r\n\tpublic pan(shift: IPoint, duration?: number): void {\r\n\t\tlet point = this.geoPointToSVG(this.zoomGeoPoint);\r\n\t\tpoint.x += this.pixelWidth * shift.x;\r\n\t\tpoint.y += this.pixelHeight * shift.y;\r\n\t\tthis.zoomToGeoPoint(this.svgPointToGeo(point), this.zoomLevel, true, duration, true);\r\n\t}\r\n\r\n\t/**\r\n\t * Current lat/long coordinates for the center of the viewport. (default\r\n\t * zoom reference point)\r\n\t *\r\n\t * @readonly\r\n\t * @return Coordinates\r\n\t */\r\n\tpublic get zoomGeoPoint(): IGeoPoint {\r\n\t\tconst point = $utils.spritePointToSvg({ x: this.pixelWidth / 2, y: this.pixelHeight / 2 }, this);\r\n\t\treturn this.svgPointToGeo(point);\r\n\t}\r\n\r\n\t/**\r\n\t * Current zoom level.\r\n\t *\r\n\t * @readonly\r\n\t * @return Zoom level\r\n\t */\r\n\tpublic set zoomLevel(value: number) {\r\n\t\tthis.seriesContainer.scale = value;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Zoom level\r\n\t */\r\n\tpublic get zoomLevel(): number {\r\n\t\treturn this.seriesContainer.scale;\r\n\t}\r\n\r\n\t/**\r\n\t * Dispatches events after some map transformation, like pan or zoom.\r\n\t *\r\n\t * @ignore\r\n\t */\r\n\tprotected handleMapTransform(): void {\r\n\t\tif (this.zoomLevel != this._prevZoomLevel) {\r\n\t\t\tthis.dispatch(\"zoomlevelchanged\");\r\n\t\t\tthis._prevZoomLevel = this.zoomLevel;\r\n\t\t\tthis.svgContainer.readerAlert(this.language.translate(\"Zoom level changed to %1\", this.language.locale, $type.castString(this.zoomLevel)));\r\n\t\t}\r\n\r\n\t\tif (this.zoomGeoPoint && (this._prevZoomGeoPoint.latitude != this.zoomGeoPoint.latitude || this._prevZoomGeoPoint.longitude != this.zoomGeoPoint.longitude)) {\r\n\t\t\tthis.dispatch(\"mappositionchanged\");\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * A [[SmallMap]] to be used on the map.\r\n\t *\r\n\t * Please note, that accessing this property will NOT create a small map\r\n\t * if it has not yet been created. (except in JSON)\r\n\t *\r\n\t * ```TypeScript\r\n\t * // Create a small map\r\n\t * map.smallMap = new am4maps.SmallMap();\r\n\t * ```\r\n\t * ```JavaScript\r\n\t * // Create a small map\r\n\t * map.smallMap = new am4maps.SmallMap();\r\n\t * ```\r\n\t * ```JSON\r\n\t * {\r\n\t * // ...\r\n\t * \"smallMap\": {}\r\n\t * // ...\r\n\t * }\r\n\t * ```\r\n\t *\r\n\t * @param smallMap Small map\r\n\t */\r\n\tpublic set smallMap(smallMap: SmallMap) {\r\n\t\tif (this._smallMap) {\r\n\t\t\tthis.removeDispose(this._smallMap);\r\n\t\t}\r\n\t\tthis._smallMap = smallMap;\r\n\t\tthis._smallMap.chart = this;\r\n\t\tsmallMap.parent = this.chartContainer;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Small map\r\n\t */\r\n\tpublic get smallMap(): SmallMap {\r\n\t\tif (!this._smallMap) {\r\n\t\t\tlet smallMap: SmallMap = new SmallMap();\r\n\t\t\tthis.smallMap = smallMap;\r\n\t\t}\r\n\t\treturn this._smallMap;\r\n\t}\r\n\r\n\t/**\r\n\t * A [[ZoomControl]] to be used on the map.\r\n\t *\r\n\t * Please note, that accessing this property will NOT create a zoom control\r\n\t * if it has not yet been created. (except in JSON)\r\n\t *\r\n\t * ```TypeScript\r\n\t * // Create a zoom control\r\n\t * map.zoomControl = new am4maps.ZoomControl();\r\n\t * ```\r\n\t * ```JavaScript\r\n\t * // Create a zoom control\r\n\t * map.zoomControl = new am4maps.ZoomControl();\r\n\t * ```\r\n\t * ```JSON\r\n\t * {\r\n\t * // ...\r\n\t * \"zoomControl\": {}\r\n\t * // ...\r\n\t * }\r\n\t * ```\r\n\t *\r\n\t * @param zoomControl Zoom control\r\n\t */\r\n\tpublic set zoomControl(zoomControl: ZoomControl) {\r\n\t\tif (this._zoomControl) {\r\n\t\t\tthis.removeDispose(this._zoomControl);\r\n\t\t}\r\n\t\tthis._zoomControl = zoomControl;\r\n\t\tzoomControl.chart = this;\r\n\t\tzoomControl.parent = this.chartContainer;\r\n\t\tzoomControl.plusButton.exportable = false;\r\n\t\tzoomControl.minusButton.exportable = false;\r\n\t}\r\n\r\n\t/**\r\n\t * @return Zoom control\r\n\t */\r\n\tpublic get zoomControl(): ZoomControl {\r\n\t\treturn this._zoomControl;\r\n\t}\r\n\r\n\t/**\r\n\t * Creates and returns a map series of appropriate type.\r\n\t *\r\n\t * @return Map series\r\n\t */\r\n\tprotected createSeries(): this[\"_seriesType\"] {\r\n\t\treturn new MapSeries();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Degrees to rotate the map around vertical axis (Y).\r\n\t *\r\n\t * E.g. if set to -160, the longitude 20 will become a new center, creating\r\n\t * a Pacific-centered map.\r\n\t *\r\n\t * @see {@link https://www.amcharts.com/docs/v4/chart-types/map/#Map_rotation} For more info on map rotation.\r\n\t * @param value Rotation\r\n\t */\r\n\tpublic set deltaLongitude(value: number) {\r\n\t\tvalue = $math.round(value, 3);\r\n\t\tif (this.setPropertyValue(\"deltaLongitude\", $geo.wrapAngleTo180(value))) {\r\n\t\t\tthis.rotateMap();\r\n\t\t\tthis.updateZoomGeoPoint();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Rotation\r\n\t */\r\n\tpublic get deltaLongitude(): number {\r\n\t\treturn this.getPropertyValue(\"deltaLongitude\");\r\n\t}\r\n\r\n\t/**\r\n\t * Degrees to rotate the map around horizontal axis (X).\r\n\t *\r\n\t * E.g. setting this to 90 will put Antarctica directly in the center of\r\n\t * the map.\r\n\t *\r\n\t * @see {@link https://www.amcharts.com/docs/v4/chart-types/map/#Map_rotation} For more info on map rotation.\r\n\t * @since 4.3.0\r\n\t * @param value Rotation\r\n\t */\r\n\tpublic set deltaLatitude(value: number) {\r\n\t\tvalue = $math.round(value, 3);\r\n\t\tif (this.setPropertyValue(\"deltaLatitude\", value)) {\r\n\t\t\tthis.rotateMap();\r\n\t\t\tthis.updateZoomGeoPoint();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Rotation\r\n\t */\r\n\tpublic get deltaLatitude(): number {\r\n\t\treturn this.getPropertyValue(\"deltaLatitude\");\r\n\t}\r\n\r\n\t/**\r\n\t * Degrees to rotate the map around \"Z\" axis. This is the axis that pierces\r\n\t * the globe directly from the viewer's point of view.\r\n\t *\r\n\t * @see {@link https://www.amcharts.com/docs/v4/chart-types/map/#Map_rotation} For more info on map rotation.\r\n\t * @since 4.3.0\r\n\t * @param value Rotation\r\n\t */\r\n\tpublic set deltaGamma(value: number) {\r\n\t\tvalue = $math.round(value, 3);\r\n\t\tif (this.setPropertyValue(\"deltaGamma\", value)) {\r\n\t\t\tthis.rotateMap();\r\n\t\t\tthis.updateZoomGeoPoint();\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @return Rotation\r\n\t */\r\n\tpublic get deltaGamma(): number {\r\n\t\treturn this.getPropertyValue(\"deltaGamma\");\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected rotateMap() {\r\n\t\tif (this.projection.d3Projection) {\r\n\t\t\tif (this.projection.d3Projection.rotate) {\r\n\t\t\t\tthis.projection.d3Projection.rotate([this.deltaLongitude, this.deltaLatitude, this.deltaGamma]);\r\n\t\t\t\tthis.invalidateProjection();\r\n\t\t\t\t//this.updateExtremes(); // removal fixes #3292\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Maximum portion of the map's width/height to allow panning \"off screen\".\r\n\t *\r\n\t * A value of 0 (zero) will prevent any portion of the the map to be panned\r\n\t * outside the viewport.\r\n\t *\r\n\t * 0.5 will allow half of the map to be outside viewable area.\r\n\t *\r\n\t * @default 0.7\r\n\t * @param value Max pan out\r\n\t */\r\n\tpublic set maxPanOut(value: number) {\r\n\t\tthis.setPropertyValue(\"maxPanOut\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Max pan out\r\n\t */\r\n\tpublic get maxPanOut(): number {\r\n\t\treturn this.getPropertyValue(\"maxPanOut\");\r\n\t}\r\n\r\n\t/**\r\n\t * The geographical point to center map on when it is first loaded.\r\n\t *\r\n\t * The map will also be centered to this point when you call `goHome()`\r\n\t * method.\r\n\t *\r\n\t * @param value Home geo point\r\n\t */\r\n\tpublic set homeGeoPoint(value: IGeoPoint) {\r\n\t\tthis.setPropertyValue(\"homeGeoPoint\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Home geo point\r\n\t */\r\n\tpublic get homeGeoPoint(): IGeoPoint {\r\n\t\treturn this.getPropertyValue(\"homeGeoPoint\");\r\n\t}\r\n\r\n\t/**\r\n\t * The zoom level to put the map in when it is first loaded.\r\n\t *\r\n\t * The map will also be set to this zoom level when you call `goHome()`\r\n\t * method.\r\n\t *\r\n\t * @param value Home zoom level\r\n\t */\r\n\tpublic set homeZoomLevel(value: number) {\r\n\t\tthis.setPropertyValue(\"homeZoomLevel\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Home zoom level\r\n\t */\r\n\tpublic get homeZoomLevel(): number {\r\n\t\treturn this.getPropertyValue(\"homeZoomLevel\");\r\n\t}\r\n\r\n\t/**\r\n\t * When user zooms in or out current zoom level is multiplied or divided\r\n\t * by value of this setting.\r\n\t *\r\n\t * @default 2\r\n\t * @param value Zoom factor\r\n\t */\r\n\tpublic set zoomStep(value: number) {\r\n\t\tthis.setPropertyValue(\"zoomStep\", value);\r\n\t}\r\n\r\n\t/**\r\n\t * @return Zoom factor\r\n\t */\r\n\tpublic get zoomStep(): number {\r\n\t\treturn this.getPropertyValue(\"zoomStep\");\r\n\t}\r\n\r\n\t/**\r\n\t * Invalidates projection, causing all series to be redrawn.\r\n\t *\r\n\t * Call this after changing projection or its settings.\r\n\t */\r\n\tpublic invalidateProjection() {\r\n\t\tthis.east = undefined;\r\n\t\tthis.invalidateDataUsers();\r\n\t\tthis.updateCenterGeoPoint();\r\n\t}\r\n\r\n\t/**\r\n\t * Sets a [[DataSource]] to be used for loading Component's data.\r\n\t *\r\n\t * @param value Data source\r\n\t */\r\n\tpublic set geodataSource(value: DataSource) {\r\n\t\tif (this._dataSources[\"geodata\"]) {\r\n\t\t\tthis.removeDispose(this._dataSources[\"geodata\"]);\r\n\t\t}\r\n\t\tthis._dataSources[\"geodata\"] = value;\r\n\t\tthis._dataSources[\"geodata\"].component = this;\r\n\t\tthis.events.on(\"inited\", () => {\r\n\t\t\tthis.loadData(\"geodata\")\r\n\t\t}, this, false);\r\n\t\tthis.setDataSourceEvents(value, \"geodata\");\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a [[DataSource]] specifically for loading Component's data.\r\n\t *\r\n\t * @return Data source\r\n\t */\r\n\tpublic get geodataSource(): DataSource {\r\n\t\tif (!this._dataSources[\"geodata\"]) {\r\n\t\t\tthis.getDataSource(\"geodata\");\r\n\t\t}\r\n\t\treturn this._dataSources[\"geodata\"];\r\n\t}\r\n\r\n\t/**\r\n\t * Processes JSON-based config before it is applied to the object.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @param config Config\r\n\t */\r\n\tpublic processConfig(config?: { [index: string]: any }): void {\r\n\r\n\t\tif ($type.hasValue(config[\"geodata\"]) && $type.isString(config[\"geodata\"])) {\r\n\t\t\tconst name = config[\"geodata\"];\r\n\t\t\t// Check if there's a map loaded by such name\r\n\t\t\tif ($type.hasValue((window)[\"am4geodata_\" + config[\"geodata\"]])) {\r\n\t\t\t\tconfig[\"geodata\"] = (window)[\"am4geodata_\" + config[\"geodata\"]];\r\n\t\t\t}\r\n\t\t\t// Nope. Let's try maybe we got JSON as string?\r\n\t\t\telse {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tconfig[\"geodata\"] = JSON.parse(config[\"geodata\"]);\r\n\t\t\t\t}\r\n\t\t\t\tcatch (e) {\r\n\t\t\t\t\t// No go again. Error out.\r\n\t\t\t\t\tthis.raiseCriticalError(Error(\"MapChart error: Geodata `\" + name + \"` is not loaded or is incorrect.\"), true);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// Instantiate projection\r\n\t\tif ($type.hasValue(config[\"projection\"]) && $type.isString(config[\"projection\"])) {\r\n\t\t\tconfig[\"projection\"] = this.createClassInstance(config[\"projection\"]);\r\n\t\t}\r\n\r\n\t\t// Set up small map\r\n\t\tif ($type.hasValue(config.smallMap) && !$type.hasValue(config.smallMap.type)) {\r\n\t\t\tconfig.smallMap.type = \"SmallMap\";\r\n\t\t}\r\n\r\n\t\t// Set up zoom control\r\n\t\tif ($type.hasValue(config.zoomControl) && !$type.hasValue(config.zoomControl.type)) {\r\n\t\t\tconfig.zoomControl.type = \"ZoomControl\";\r\n\t\t}\r\n\r\n\t\tsuper.processConfig(config);\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Decorates a new [[Series]] object with required parameters when it is\r\n\t * added to the chart.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @param event Event\r\n\t */\r\n\tpublic handleSeriesAdded(event: IListEvents[\"inserted\"]): void {\r\n\t\tsuper.handleSeriesAdded(event);\r\n\t\tlet series = event.newValue;\r\n\t\tseries.scale = this.scaleRatio;\r\n\t\tseries.events.on(\"validated\", this.updateCenterGeoPoint, this, false);\r\n\t}\r\n\r\n\r\n\t/**\r\n \t * This function is used to sort element's JSON config properties, so that\r\n \t * some properties that absolutely need to be processed last, can be put at\r\n \t * the end.\r\n \t *\r\n \t * @ignore Exclude from docs\r\n \t * @param a Element 1\r\n \t * @param b Element 2\r\n \t * @return Sorting number\r\n \t */\r\n\tprotected configOrder(a: string, b: string): Ordering {\r\n\t\tif (a == b) {\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\t// Must come last\r\n\t\telse if (a == \"smallMap\") {\r\n\t\t\treturn 1;\r\n\t\t}\r\n\t\telse if (b == \"smallMap\") {\r\n\t\t\treturn -1;\r\n\t\t}\r\n\t\telse if (a == \"series\") {\r\n\t\t\treturn 1;\r\n\t\t}\r\n\t\telse if (b == \"series\") {\r\n\t\t\treturn -1;\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn super.configOrder(a, b);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Adds `projection` to \"as is\" fields.\r\n\t *\r\n\t * @param field Field name\r\n\t * @return Assign as is?\r\n\t */\r\n\tprotected asIs(field: string): boolean {\r\n\t\treturn field == \"projection\" || field == \"geodata\" || super.asIs(field);\r\n\t}\r\n\r\n\t/**\r\n\t * Geo point of map center\r\n\t *\r\n\t * @readonly\r\n\t */\r\n\tpublic get centerGeoPoint(): IGeoPoint {\r\n\t\treturn this._centerGeoPoint;\r\n\t}\r\n\r\n\t/**\r\n\t * Resets the map to its original position and zoom level.\r\n\t *\r\n\t * Use the only parameter to set number of milliseconds for the zoom\r\n\t * animation to play.\r\n\t *\r\n\t * @param duration Duration (ms)\r\n\t */\r\n\tpublic goHome(duration?: number) {\r\n\t\tlet homeGeoPoint = this.homeGeoPoint;\r\n\t\tif (!homeGeoPoint) {\r\n\t\t\thomeGeoPoint = this.centerGeoPoint;\r\n\t\t}\r\n\t\tif (homeGeoPoint) {\r\n\t\t\tthis.zoomToGeoPoint(homeGeoPoint, this.homeZoomLevel, true, duration, true);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Sets [[Paper]] instance to use to draw elements.\r\n\t *\r\n\t * @ignore\r\n\t * @param paper Paper\r\n\t * @return true if paper was changed, false, if it's the same\r\n\t */\r\n\tpublic setPaper(paper: Paper): boolean {\r\n\t\tif (this.svgContainer) {\r\n\t\t\tthis.svgContainer.hideOverflow = true;\r\n\t\t}\r\n\r\n\t\treturn super.setPaper(paper);\r\n\t}\r\n\r\n\t/**\r\n\t * Background series will create polygons that will fill all the map area\r\n\t * with some color (or other fill).\r\n\t *\r\n\t * This might be useful with non-rectangular projections, like Orthographic,\r\n\t * Albers, etc.\r\n\t *\r\n\t * To change background color/opacity access polygon template.\r\n\t *\r\n\t * ```TypeScript\r\n\t * chart.backgroundSeries.mapPolygons.template.polygon.fill = am4core.color(\"#fff\");\r\n\t * chart.backgroundSeries.mapPolygons.template.polygon.fillOpacity = 0.1;\r\n\t * ```\r\n\t * ```JavaScript\r\n\t * chart.backgroundSeries.mapPolygons.template.polygon.fill = am4core.color(\"#fff\");\r\n\t * chart.backgroundSeries.mapPolygons.template.polygon.fillOpacity = 0.1;\r\n\t * ```\r\n\t * ```JSON\r\n\t * {\r\n\t * \"backgroundSeries\": {\r\n\t * \"mapPolygons\": {\r\n\t * \"polygon\": {\r\n\t * \"fill\": \"#fff\",\r\n\t * \"fillOpacity\": 0.1\r\n\t * }\r\n\t * }\r\n\t * }\r\n\t * }\r\n\t * ```\r\n\t *\r\n\t * @since 4.3.0\r\n\t */\r\n\tpublic get backgroundSeries(): MapPolygonSeries {\r\n\t\tif (!this._backgroundSeries) {\r\n\t\t\tlet backgroundSeries = new MapPolygonSeries();\r\n\t\t\tbackgroundSeries.parent = this.seriesContainer;\r\n\t\t\tbackgroundSeries.chart = this;\r\n\r\n\t\t\tbackgroundSeries.hiddenInLegend = true;\r\n\t\t\tbackgroundSeries.mapPolygons.template.focusable = false;\r\n\t\t\tbackgroundSeries.addDisposer(new Disposer(() => {\r\n\t\t\t\tthis._backgroundSeries = undefined;\r\n\t\t\t}))\r\n\t\t\tthis._disposers.push(backgroundSeries);\r\n\r\n\t\t\tlet interfaceColors = new InterfaceColorSet();\r\n\t\t\tlet color = interfaceColors.getFor(\"background\");\r\n\r\n\t\t\tlet polygonTemplate = backgroundSeries.mapPolygons.template.polygon;\r\n\t\t\tpolygonTemplate.stroke = color;\r\n\t\t\tpolygonTemplate.fill = color;\r\n\t\t\tpolygonTemplate.fillOpacity = 0;\r\n\t\t\tpolygonTemplate.strokeOpacity = 0;\r\n\t\t\t//polygonTemplate.focusable = false;\r\n\r\n\t\t\tbackgroundSeries.mapPolygons.create();\r\n\r\n\t\t\tthis._backgroundSeries = backgroundSeries;\r\n\t\t}\r\n\r\n\t\treturn this._backgroundSeries;\r\n\t}\r\n\r\n\t/**\r\n\t * Prepares the legend instance for use in this chart.\r\n\t *\r\n\t * @param legend Legend\r\n\t */\r\n\tprotected setLegend(legend: Legend) {\r\n\t\tsuper.setLegend(legend);\r\n\t\tif (legend) {\r\n\t\t\tlegend.parent = this;\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @param value Tap to activate?\r\n\t */\r\n\tprotected setTapToActivate(value: boolean): void {\r\n\t\tsuper.setTapToActivate(value);\r\n\t\t// setup other containers\r\n\t\tthis.seriesContainer.interactions.isTouchProtected = true;\r\n\t\tthis.panSprite.interactions.isTouchProtected = true;\r\n\t}\r\n\r\n\tprotected handleTapToActivate(): void {\r\n\t\tsuper.handleTapToActivate();\r\n\t\tthis.seriesContainer.interactions.isTouchProtected = false;\r\n\t\tthis.panSprite.interactions.isTouchProtected = false;\r\n\t}\r\n\r\n\tprotected handleTapToActivateDeactivation(): void {\r\n\t\tsuper.handleTapToActivateDeactivation();\r\n\t\tthis.seriesContainer.interactions.isTouchProtected = true;\r\n\t\tthis.panSprite.interactions.isTouchProtected = true;\r\n\t}\r\n\r\n\t/**\r\n\t * Adds easing functions to \"function\" fields.\r\n\t *\r\n\t * @param field Field name\r\n\t * @return Assign as function?\r\n\t */\r\n\tprotected asFunction(field: string): boolean {\r\n\t\treturn field == \"zoomEasing\" || super.asIs(field);\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t * @return Has license?\r\n\t */\r\n\tpublic hasLicense(): boolean {\r\n\t\tif (options.commercialLicense) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\tif (!super.hasLicense()) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\tfor (let i = 0; i < options.licenses.length; i++) {\r\n\t\t\tif (options.licenses[i].match(/^MP.{5,}/i)) {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false;\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapChart\"] = MapChart;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/types/MapChart.ts","/**\r\n * Map spline module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapLine, IMapLineProperties, IMapLineAdapters, IMapLineEvents } from \"./MapLine\";\r\nimport { Polyspline } from \"../../core/elements/Polyspline\";\r\nimport { MapSplineSeriesDataItem, MapSplineSeries } from \"./MapSplineSeries\";\r\nimport { registry } from \"../../core/Registry\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[MapSpline]].\r\n */\r\nexport interface IMapSplineProperties extends IMapLineProperties { }\r\n\r\n/**\r\n * Defines events for [[MapSpline]].\r\n */\r\nexport interface IMapSplineEvents extends IMapLineEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapSpline]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapSplineAdapters extends IMapLineAdapters, IMapSplineProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Used to draw a spline on the map.\r\n *\r\n * @see {@link IMapSplineEvents} for a list of available events\r\n * @see {@link IMapSplineAdapters} for a list of available Adapters\r\n */\r\nexport class MapSpline extends MapLine {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapSplineProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapSplineAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapSplineEvents;\r\n\r\n\t/**\r\n\t * A visual element for the spline.\r\n\t */\r\n\tpublic line: Polyspline;\r\n\r\n\t/**\r\n\t * A related data item.\r\n\t */\r\n\tpublic _dataItem: MapSplineSeriesDataItem;\r\n\r\n\t/**\r\n\t * A map series this object belongs to.\r\n\t */\r\n\tpublic series: MapSplineSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapSpline\";\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected createLine(){\r\n\t\tthis.line = new Polyspline();\r\n\t\tthis.line.tensionX = 0.8;\r\n\t\tthis.line.tensionY = 0.8;\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * ShortestDistance = true is not supported by MapSpline, only MapLine does support it\r\n\t * @default false\r\n\t * @param value\r\n\t * @todo: review description\r\n\t */\r\n\tpublic get shortestDistance(): boolean {\r\n\t\treturn false;\r\n\t}\r\n\r\n\tpublic set shortestDistance(value: boolean) {\r\n\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapSpline\"] = MapSpline;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapSpline.ts","/**\r\n * Map arched line module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapLine, IMapLineProperties, IMapLineAdapters, IMapLineEvents } from \"./MapLine\";\r\nimport { Polyarc } from \"../../core/elements/Polyarc\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport { MapArcSeries } from \"./MapArcSeries\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[MapArc]].\r\n */\r\nexport interface IMapArcProperties extends IMapLineProperties { }\r\n\r\n/**\r\n * Defines events for [[MapArc]].\r\n */\r\nexport interface IMapArcEvents extends IMapLineEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapArc]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapArcAdapters extends IMapLineAdapters, IMapArcProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Used to draw an arched line on the map.\r\n *\r\n * @see {@link IMapArcEvents} for a list of available events\r\n * @see {@link IMapArcAdapters} for a list of available Adapters\r\n */\r\nexport class MapArc extends MapLine {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapArcProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapArcAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapArcEvents;\r\n\r\n\t/**\r\n\t * A visual element.\r\n\t */\r\n\tpublic line: Polyarc;\r\n\r\n\t/**\r\n\t * A map series this object belongs to.\r\n\t */\r\n\tpublic series: MapArcSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\r\n\t\t// Init\r\n\t\tsuper();\r\n\t\tthis.className = \"MapArc\";\r\n\r\n\t\t// Apply theme\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected createLine(){\r\n\t\tthis.line = new Polyarc();\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * `shortestDistance = true` is not supported by `MapArc`.\r\n\t *\r\n\t * Only [[MapLine]] supports it.\r\n\t *\r\n\t * @default false\r\n\t * @param value\r\n\t */\r\n\tpublic set shortestDistance(value: boolean) {\r\n\r\n\t}\r\n\r\n\tpublic get shortestDistance(): boolean {\r\n\t\treturn false;\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapArc\"] = MapArc;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapArc.ts","/**\r\n * Map spline series module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapLineSeries, MapLineSeriesDataItem, IMapLineSeriesProperties, IMapLineSeriesDataFields, IMapLineSeriesAdapters, IMapLineSeriesEvents } from \"./MapLineSeries\";\r\nimport { MapSpline } from \"./MapSpline\";\r\nimport { registry } from \"../../core/Registry\";\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[MapSplineSeries]]\r\n * @see {@link DataItem}\r\n */\r\nexport class MapSplineSeriesDataItem extends MapLineSeriesDataItem {\r\n\r\n\t/**\r\n\t * A [[MapSpline]] element related to this data item.\r\n\t */\r\n\tpublic _mapLine: MapSpline;\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for\r\n\t */\r\n\tpublic _component!: MapSplineSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapSplineSeriesDataItem\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines data fields for [[MapSplineSeries]].\r\n */\r\nexport interface IMapSplineSeriesDataFields extends IMapLineSeriesDataFields { }\r\n\r\n/**\r\n * Defines properties for [[MapSplineSeries]].\r\n */\r\nexport interface IMapSplineSeriesProperties extends IMapLineSeriesProperties { }\r\n\r\n/**\r\n * Defines events for [[MapSplineSeries]].\r\n */\r\nexport interface IMapSplineSeriesEvents extends IMapLineSeriesEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapSplineSeries]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapSplineSeriesAdapters extends IMapLineSeriesAdapters, IMapSplineSeriesProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * A series of map spline elements.\r\n *\r\n * @see {@link IMapSplineSeriesEvents} for a list of available Events\r\n * @see {@link IMapSplineSeriesAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class MapSplineSeries extends MapLineSeries {\r\n\r\n\t/**\r\n\t * Defines available data fields.\r\n\t */\r\n\tpublic _dataFields: IMapSplineSeriesDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapSplineSeriesProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapSplineSeriesAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapSplineSeriesEvents;\r\n\r\n\t/**\r\n\t * Defines the type of data item.\r\n\t */\r\n\tpublic _dataItem: MapSplineSeriesDataItem;\r\n\r\n\t/**\r\n\t * Defines the type of the line items in this series.\r\n\t */\r\n\tpublic _mapLine: MapSpline;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapSplineSeries\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new/empty DataItem of the type appropriate for this object.\r\n\t *\r\n\t * @see {@link DataItem}\r\n\t * @return Data Item\r\n\t */\r\n\tprotected createDataItem(): this[\"_dataItem\"] {\r\n\t\treturn new MapSplineSeriesDataItem();\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new line instance of suitable type.\r\n\t *\r\n\t * @return New line\r\n\t */\r\n\tprotected createLine(): this[\"_mapLine\"] {\r\n\t\treturn new MapSpline();\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapSplineSeries\"] = MapSplineSeries;\r\nregistry.registeredClasses[\"MapSplineSeriesDataItem\"] = MapSplineSeriesDataItem;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapSplineSeries.ts","/**\r\n * Map arc series module.\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { MapLineSeries, MapLineSeriesDataItem, IMapLineSeriesProperties, IMapLineSeriesDataFields, IMapLineSeriesAdapters, IMapLineSeriesEvents } from \"./MapLineSeries\";\r\nimport { MapArc } from \"./MapArc\";\r\nimport { registry } from \"../../core/Registry\";\r\n\r\n/**\r\n * ============================================================================\r\n * DATA ITEM\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines a [[DataItem]] for [[MapArcSeries]].\r\n *\r\n * @see {@link DataItem}\r\n */\r\nexport class MapArcSeriesDataItem extends MapLineSeriesDataItem {\r\n\r\n\t/**\r\n\t * A [[MapArc]] element related to this data item.\r\n\t */\r\n\tpublic _mapLine: MapArc;\r\n\r\n\t/**\r\n\t * Defines a type of [[Component]] this data item is used for.\r\n\t */\r\n\tpublic _component!: MapArcSeries;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapArcSeriesDataItem\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n}\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines data fields for [[MapArcSeries]].\r\n */\r\nexport interface IMapArcSeriesDataFields extends IMapLineSeriesDataFields { }\r\n\r\n/**\r\n * Defines properties for [[MapArcSeries]].\r\n */\r\nexport interface IMapArcSeriesProperties extends IMapLineSeriesProperties { }\r\n\r\n/**\r\n * Defines events for [[MapArcSeries]].\r\n */\r\nexport interface IMapArcSeriesEvents extends IMapLineSeriesEvents { }\r\n\r\n/**\r\n * Defines adapters for [[MapArcSeries]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IMapArcSeriesAdapters extends IMapLineSeriesAdapters, IMapArcSeriesProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * A series of arc elements. (curved lines)\r\n *\r\n * @see {@link IMapArcSeriesEvents} for a list of available Events\r\n * @see {@link IMapArcSeriesAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class MapArcSeries extends MapLineSeries {\r\n\r\n\t/**\r\n\t * Defines available data fields.\r\n\t */\r\n\tpublic _dataFields: IMapArcSeriesDataFields;\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IMapArcSeriesProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IMapArcSeriesAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IMapArcSeriesEvents;\r\n\r\n\t/**\r\n\t * Defines the type of data item.\r\n\t */\r\n\tpublic _dataItem: MapArcSeriesDataItem;\r\n\r\n\t/**\r\n\t * Defines the type of the line items in this series.\r\n\t */\r\n\tpublic _mapLine: MapArc;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\t\tthis.className = \"MapArcSeries\";\r\n\t\tthis.applyTheme();\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new/empty DataItem of the type appropriate for this object.\r\n\t *\r\n\t * @see {@link DataItem}\r\n\t * @return Data Item\r\n\t */\r\n\tprotected createDataItem(): this[\"_dataItem\"] {\r\n\t\treturn new MapArcSeriesDataItem();\r\n\t}\r\n\r\n\t/**\r\n\t * Returns a new line instance of suitable type.\r\n\t *\r\n\t * @return New line\r\n\t */\r\n\tprotected createLine(): this[\"_mapLine\"] {\r\n\t\treturn new MapArc();\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"MapArcSeries\"] = MapArcSeries;\r\nregistry.registeredClasses[\"MapArcSeriesDataItem\"] = MapArcSeriesDataItem;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/MapArcSeries.ts","/**\r\n * Zoom control module\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Container, IContainerProperties, IContainerAdapters, IContainerEvents } from \"../../core/Container\";\r\nimport { Sprite, ISpriteEvents, AMEvent } from \"../../core/Sprite\";\r\nimport { Button } from \"../../core/elements/Button\";\r\nimport { MapChart } from \"../types/MapChart\";\r\nimport { RoundedRectangle } from \"../../core/elements/RoundedRectangle\";\r\nimport { MutableValueDisposer, MultiDisposer } from \"../../core/utils/Disposer\";\r\nimport { keyboard } from \"../../core/utils/Keyboard\";\r\nimport { getInteraction } from \"../../core/interaction/Interaction\";\r\nimport { percent } from \"../../core/utils/Percent\";\r\nimport { registry } from \"../../core/Registry\";\r\nimport { InterfaceColorSet } from \"../../core/utils/InterfaceColorSet\";\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * REQUISITES\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Defines properties for [[ZoomControl]].\r\n */\r\nexport interface IZoomControlProperties extends IContainerProperties { }\r\n\r\n/**\r\n * Defines events for [[ZoomControl]].\r\n */\r\nexport interface IZoomControlEvents extends IContainerEvents { }\r\n\r\n/**\r\n * Defines adapters for [[ZoomControl]].\r\n *\r\n * @see {@link Adapter}\r\n */\r\nexport interface IZoomControlAdapters extends IContainerAdapters, IZoomControlProperties { }\r\n\r\n\r\n/**\r\n * ============================================================================\r\n * MAIN CLASS\r\n * ============================================================================\r\n * @hidden\r\n */\r\n\r\n/**\r\n * Creates a control for zooming the map.\r\n *\r\n * @see {@link IZoomControlEvents} for a list of available events\r\n * @see {@link IZoomControlAdapters} for a list of available Adapters\r\n * @important\r\n */\r\nexport class ZoomControl extends Container {\r\n\r\n\t/**\r\n\t * Defines available properties.\r\n\t */\r\n\tpublic _properties!: IZoomControlProperties;\r\n\r\n\t/**\r\n\t * Defines available adapters.\r\n\t */\r\n\tpublic _adapter!: IZoomControlAdapters;\r\n\r\n\t/**\r\n\t * Defines available events.\r\n\t */\r\n\tpublic _events!: IZoomControlEvents;\r\n\r\n\t/**\r\n\t * Zoom in button element.\r\n\t */\r\n\tpublic plusButton: Button;\r\n\r\n\t/**\r\n\t * Zoom out button element.\r\n\t */\r\n\tpublic minusButton: Button;\r\n\r\n\t/**\r\n\t * A zoom slider background element.\r\n\t */\r\n\tpublic slider: Container;\r\n\r\n\t/**\r\n\t * A zoom slider thumb element.\r\n\t */\r\n\tpublic thumb: Button;\r\n\r\n\t/**\r\n\t * A target map.\r\n\t */\r\n\tprotected _chart: MutableValueDisposer = new MutableValueDisposer();\r\n\r\n\t/**\r\n\t * A type to use for the background element for zoom control.\r\n\t */\r\n\tpublic _background: RoundedRectangle;\r\n\r\n\t/**\r\n\t * Constructor\r\n\t */\r\n\tconstructor() {\r\n\t\tsuper();\r\n\r\n\t\tthis.className = \"ZoomControl\";\r\n\r\n\t\tthis.align = \"right\";\r\n\t\tthis.valign = \"bottom\";\r\n\r\n\t\tthis.layout = \"vertical\";\r\n\t\tthis.padding(5, 5, 5, 5);\r\n\r\n\t\tlet interfaceColors = new InterfaceColorSet();\r\n\r\n\t\tlet plusButton: Button = this.createChild(Button);\r\n\t\tplusButton.shouldClone = false;\r\n\t\tplusButton.label.text = \"+\";\r\n\t\t//plusButton.fontFamily = \"Verdana\";\r\n\t\tthis.plusButton = plusButton;\r\n\r\n\t\tlet slider: Container = this.createChild(Container);\r\n\t\tslider.shouldClone = false;\r\n\t\tslider.background.fill = interfaceColors.getFor(\"alternativeBackground\");\r\n\t\tslider.background.fillOpacity = 0.05;\r\n\t\tslider.background.events.on(\"hit\", this.handleBackgroundClick, this, false);\r\n\t\tslider.events.on(\"sizechanged\", this.updateThumbSize, this, false);\r\n\t\tthis.slider = slider;\r\n\r\n\t\tlet thumb: Button = slider.createChild(Button);\r\n\t\tthumb.shouldClone = false;\r\n\t\tthumb.padding(0, 0, 0, 0);\r\n\t\tthumb.draggable = true;\r\n\t\tthumb.events.on(\"drag\", this.handleThumbDrag, this, false);\r\n\t\tthis.thumb = thumb;\r\n\r\n\t\tlet minusButton: Button = this.createChild(Button);\r\n\t\tminusButton.shouldClone = false;\r\n\t\tminusButton.label.text = \"-\";\r\n\t\t//minusButton.fontFamily = \"Verdana\";\r\n\t\tthis.minusButton = minusButton;\r\n\r\n\t\t// Set roles\r\n\t\tthis.thumb.role = \"slider\";\r\n\t\tthis.thumb.readerLive = \"polite\";\r\n\r\n\t\t// Set reader text\r\n\t\tthis.thumb.readerTitle = this.language.translate(\"Use arrow keys to zoom in and out\");\r\n\t\tthis.minusButton.readerTitle = this.language.translate(\"Press ENTER to zoom in\");\r\n\t\tthis.plusButton.readerTitle = this.language.translate(\"Press ENTER to zoom out\");\r\n\r\n\t\tthis.applyTheme();\r\n\r\n\t\tthis.events.on(\"propertychanged\", (event) => {\r\n\t\t\tif (event.property == \"layout\") {\r\n\t\t\t\tthis.fixLayout();\r\n\t\t\t}\r\n\t\t}, undefined, false);\r\n\r\n\t\tthis._disposers.push(this._chart);\r\n\r\n\t\tthis.fixLayout();\r\n\t}\r\n\r\n\t/**\r\n\t * @ignore\r\n\t */\r\n\tprotected fixLayout() {\r\n\r\n\t\tlet plusButton = this.plusButton;\r\n\t\tlet minusButton = this.minusButton;\r\n\r\n\t\tlet thumb = this.thumb;\r\n\t\tlet slider = this.slider;\r\n\r\n\t\tplusButton.x = undefined;\r\n\t\tplusButton.y = undefined;\r\n\r\n\t\tminusButton.x = undefined;\r\n\t\tminusButton.y = undefined;\r\n\r\n\t\tthumb.x = undefined;\r\n\t\tthumb.y = undefined;\r\n\r\n\t\tslider.x = undefined;\r\n\t\tslider.y = undefined;\r\n\r\n\t\tplusButton.padding(6, 10, 6, 10);\r\n\t\tminusButton.padding(6, 10, 6, 10);\r\n\r\n\t\tminusButton.label.align = \"center\";\r\n\t\tminusButton.label.valign = \"middle\";\r\n\r\n\t\tplusButton.label.align = \"center\";\r\n\t\tplusButton.label.valign = \"middle\";\r\n\r\n\t\tif (this.layout == \"vertical\") {\r\n\t\t\tthis.width = 40;\r\n\t\t\tthis.height = undefined;\r\n\r\n\t\t\tminusButton.width = percent(100);\r\n\t\t\tminusButton.height = undefined;\r\n\r\n\t\t\tthumb.width = percent(100);\r\n\t\t\tthumb.height = undefined;\r\n\r\n\t\t\tplusButton.width = percent(100);\r\n\t\t\tplusButton.height = undefined;\r\n\r\n\t\t\tslider.width = percent(100);\r\n\t\t\tminusButton.marginTop = 1;\r\n\t\t\tplusButton.marginBottom = 2;\r\n\r\n\t\t\tslider.height = 0;\r\n\r\n\t\t\tminusButton.toFront();\r\n\t\t\tplusButton.toBack();\r\n\r\n\t\t\tthumb.minX = 0;\r\n\t\t\tthumb.maxX = 0;\r\n\t\t\tthumb.minY = 0;\r\n\r\n\r\n\t\t}\r\n\t\telse if (this.layout == \"horizontal\") {\r\n\t\t\tthis.height = 40;\r\n\t\t\tthis.width = undefined;\r\n\r\n\t\t\tminusButton.height = percent(100);\r\n\t\t\tminusButton.width = undefined;\r\n\r\n\t\t\tplusButton.height = percent(100);\r\n\t\t\tplusButton.width = undefined;\r\n\r\n\t\t\tthumb.height = percent(100);\r\n\t\t\tthumb.width = undefined;\r\n\r\n\t\t\tthumb.minX = 0;\r\n\t\t\tthumb.minY = 0;\r\n\t\t\tthumb.maxY = 0;\r\n\r\n\t\t\tslider.height = percent(100);\r\n\t\t\tslider.width = 0;\r\n\r\n\t\t\tminusButton.toBack();\r\n\t\t\tplusButton.toFront();\r\n\t\t}\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Handles zoom operation after clicking on the slider background.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @param event Event\r\n\t */\r\n\tpublic handleBackgroundClick(event: AMEvent[\"hit\"]): void {\r\n\t\tlet sprite: Sprite = event.target;\r\n\t\tlet y: number = event.spritePoint.y;\r\n\t\tlet chart: MapChart = this.chart;\r\n\r\n\t\tlet maxPower: number = Math.log(chart.maxZoomLevel) / Math.LN2;\r\n\t\tlet minPower: number = Math.log(chart.minZoomLevel) / Math.LN2;\r\n\r\n\t\tlet power: number = (sprite.pixelHeight - y) / sprite.pixelHeight * (minPower + (maxPower - minPower));\r\n\t\tlet zoomLevel: number = Math.pow(2, power);\r\n\t\tchart.zoomToGeoPoint(chart.zoomGeoPoint, zoomLevel);\r\n\t}\r\n\r\n\t/**\r\n\t * A main chart/map that this zoom control is for.\r\n\t *\r\n\t * @param chart Map/chart\r\n\t */\r\n\tpublic set chart(chart: MapChart) {\r\n\t\tthis._chart.set(chart, new MultiDisposer([\r\n\t\t\tchart.events.on(\"maxsizechanged\", this.updateThumbSize, this, false),\r\n\t\t\tchart.events.on(\"zoomlevelchanged\", this.updateThumb, this, false),\r\n\r\n\t\t\tthis.minusButton.events.on(\"hit\", () => { chart.zoomOut(chart.zoomGeoPoint) }, chart, false),\r\n\r\n\t\t\tgetInteraction().body.events.on(\"keyup\", (ev) => {\r\n\t\t\t\tif (this.topParent.hasFocused) {\r\n\t\t\t\t\t// ENTER is now handled globally\r\n\t\t\t\t\tif (keyboard.isKey(ev.event, \"plus\")) {\r\n\t\t\t\t\t\tchart.zoomIn();\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if (keyboard.isKey(ev.event, \"minus\")) {\r\n\t\t\t\t\t\tchart.zoomOut();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}, chart),\r\n\t\t\tthis.plusButton.events.on(\"hit\", () => { chart.zoomIn(chart.zoomGeoPoint) }, chart, false)\r\n\t\t]));\r\n\t}\r\n\r\n\t/**\r\n\t * @return Map/chart\r\n\t */\r\n\tpublic get chart(): MapChart {\r\n\t\treturn this._chart.get();\r\n\t}\r\n\r\n\t/**\r\n\t * Updates the slider's thumb size based on the available zoom space.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic updateThumbSize(): void {\r\n\t\tlet chart = this.chart;\r\n\t\tif (chart) {\r\n\t\t\tlet slider: Container = this.slider;\r\n\t\t\tlet thumb: Button = this.thumb;\r\n\t\t\tif (this.layout == \"vertical\") {\r\n\t\t\t\tthumb.minHeight = Math.min(this.slider.pixelHeight, 20);\r\n\r\n\t\t\t\tthumb.height = slider.pixelHeight / this.stepCount;\r\n\t\t\t\tthumb.maxY = slider.pixelHeight - thumb.pixelHeight;\r\n\r\n\t\t\t\tif (thumb.pixelHeight <= 1) {\r\n\t\t\t\t\tthumb.visible = false;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tthumb.visible = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthumb.minWidth = Math.min(this.slider.pixelWidth, 20);\r\n\t\t\t\tthumb.width = slider.pixelWidth / this.stepCount;\r\n\t\t\t\tthumb.maxX = slider.pixelWidth - thumb.pixelWidth;\r\n\r\n\t\t\t\tif (thumb.pixelWidth <= 1) {\r\n\t\t\t\t\tthumb.visible = false;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tthumb.visible = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Updates thumb according to current zoom position from map.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic updateThumb(): void {\r\n\t\tlet slider: Container = this.slider;\r\n\t\tlet chart: MapChart = this.chart;\r\n\t\tlet thumb: Button = this.thumb;\r\n\r\n\t\tif (!thumb.isDown) {\r\n\t\t\tlet step: number = (Math.log(chart.zoomLevel) - Math.log(this.chart.minZoomLevel)) / Math.LN2;\r\n\r\n\t\t\tif (this.layout == \"vertical\") {\r\n\t\t\t\tthumb.y = slider.pixelHeight - (slider.pixelHeight - thumb.pixelHeight) * step / this.stepCount - thumb.pixelHeight;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthumb.x = slider.pixelWidth * step / this.stepCount;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Zooms the actual map when slider position changes.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t */\r\n\tpublic handleThumbDrag(): void {\r\n\t\tlet slider: Container = this.slider;\r\n\t\tlet chart: MapChart = this.chart;\r\n\t\tlet thumb: Button = this.thumb;\r\n\t\tlet step: number;\r\n\r\n\t\tlet minStep = Math.log(this.chart.minZoomLevel) / Math.LN2;\r\n\r\n\t\tif (this.layout == \"vertical\") {\r\n\t\t\tstep = this.stepCount * (slider.pixelHeight - thumb.pixelY - thumb.pixelHeight) / (slider.pixelHeight - thumb.pixelHeight);\r\n\t\t}\r\n\t\telse {\r\n\t\t\tstep = this.stepCount * thumb.pixelX / slider.pixelWidth;\r\n\t\t}\r\n\t\tstep = minStep + step;\r\n\r\n\t\tlet zoomLevel: number = Math.pow(2, step);\r\n\t\tchart.zoomToGeoPoint(undefined, zoomLevel, false, 0);\r\n\t}\r\n\r\n\t/**\r\n\t * Returns the step countfor the slider grid according to map's min and max\r\n\t * zoom level settings.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @return Step count\r\n\t */\r\n\tpublic get stepCount(): number {\r\n\t\treturn Math.log(this.chart.maxZoomLevel) / Math.LN2 - Math.log(this.chart.minZoomLevel) / Math.LN2;\r\n\t}\r\n\r\n\t/**\r\n\t * Creates a background element for slider control.\r\n\t *\r\n\t * @ignore Exclude from docs\r\n\t * @return Background\r\n\t */\r\n\tpublic createBackground(): this[\"_background\"] {\r\n\t\treturn new RoundedRectangle();\r\n\t}\r\n\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"ZoomControl\"] = ZoomControl;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../src/.internal/charts/map/ZoomControl.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Mercator projection.\r\n */\r\nexport class Mercator extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoMercator();\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"Mercator\"] = Mercator;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/Mercator.ts","export var abs = Math.abs;\nexport var atan = Math.atan;\nexport var atan2 = Math.atan2;\nexport var ceil = Math.ceil;\nexport var cos = Math.cos;\nexport var exp = Math.exp;\nexport var floor = Math.floor;\nexport var log = Math.log;\nexport var max = Math.max;\nexport var min = Math.min;\nexport var pow = Math.pow;\nexport var round = Math.round;\nexport var sign = Math.sign || function(x) { return x > 0 ? 1 : x < 0 ? -1 : 0; };\nexport var sin = Math.sin;\nexport var tan = Math.tan;\n\nexport var epsilon = 1e-6;\nexport var epsilon2 = 1e-12;\nexport var pi = Math.PI;\nexport var halfPi = pi / 2;\nexport var quarterPi = pi / 4;\nexport var sqrt1_2 = Math.SQRT1_2;\nexport var sqrt2 = sqrt(2);\nexport var sqrtPi = sqrt(pi);\nexport var tau = pi * 2;\nexport var degrees = 180 / pi;\nexport var radians = pi / 180;\n\nexport function sinci(x) {\n return x ? x / Math.sin(x) : 1;\n}\n\nexport function asin(x) {\n return x > 1 ? halfPi : x < -1 ? -halfPi : Math.asin(x);\n}\n\nexport function acos(x) {\n return x > 1 ? 0 : x < -1 ? pi : Math.acos(x);\n}\n\nexport function sqrt(x) {\n return x > 0 ? Math.sqrt(x) : 0;\n}\n\nexport function tanh(x) {\n x = exp(2 * x);\n return (x - 1) / (x + 1);\n}\n\nexport function sinh(x) {\n return (exp(x) - exp(-x)) / 2;\n}\n\nexport function cosh(x) {\n return (exp(x) + exp(-x)) / 2;\n}\n\nexport function arsinh(x) {\n return log(x + sqrt(x * x + 1));\n}\n\nexport function arcosh(x) {\n return log(x + sqrt(x * x - 1));\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/math.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, acos, cos, epsilon, pi, sin, sinci, sqrt} from \"./math.js\";\n\nexport function aitoffRaw(x, y) {\n var cosy = cos(y), sincia = sinci(acos(cosy * cos(x /= 2)));\n return [2 * cosy * sin(x) * sincia, sin(y) * sincia];\n}\n\n// Abort if [x, y] is not within an ellipse centered at [0, 0] with\n// semi-major axis pi and semi-minor axis pi/2.\naitoffRaw.invert = function(x, y) {\n if (x * x + 4 * y * y > pi * pi + epsilon) return;\n var x1 = x, y1 = y, i = 25;\n do {\n var sinx = sin(x1),\n sinx_2 = sin(x1 / 2),\n cosx_2 = cos(x1 / 2),\n siny = sin(y1),\n cosy = cos(y1),\n sin_2y = sin(2 * y1),\n sin2y = siny * siny,\n cos2y = cosy * cosy,\n sin2x_2 = sinx_2 * sinx_2,\n c = 1 - cos2y * cosx_2 * cosx_2,\n e = c ? acos(cosy * cosx_2) * sqrt(f = 1 / c) : f = 0,\n f,\n fx = 2 * e * cosy * sinx_2 - x,\n fy = e * siny - y,\n dxdx = f * (cos2y * sin2x_2 + e * cosy * cosx_2 * sin2y),\n dxdy = f * (0.5 * sinx * sin_2y - e * 2 * siny * sinx_2),\n dydx = f * 0.25 * (sin_2y * sinx_2 - e * siny * cos2y * sinx),\n dydy = f * (sin2y * cosx_2 + e * sin2x_2 * cosy),\n z = dxdy * dydx - dydy * dxdx;\n if (!z) break;\n var dx = (fy * dxdy - fx * dydy) / z,\n dy = (fx * dydx - fy * dxdx) / z;\n x1 -= dx, y1 -= dy;\n } while ((abs(dx) > epsilon || abs(dy) > epsilon) && --i > 0);\n return [x1, y1];\n};\n\nexport default function() {\n return projection(aitoffRaw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/aitoff.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, arcosh, arsinh, asin, atan2, cos, cosh, sign, sin, sinh, sqrt, tan} from \"./math.js\";\n\nexport function augustRaw(lambda, phi) {\n var tanPhi = tan(phi / 2),\n k = sqrt(1 - tanPhi * tanPhi),\n c = 1 + k * cos(lambda /= 2),\n x = sin(lambda) * k / c,\n y = tanPhi / c,\n x2 = x * x,\n y2 = y * y;\n return [\n 4 / 3 * x * (3 + x2 - 3 * y2),\n 4 / 3 * y * (3 + 3 * x2 - y2)\n ];\n}\n\naugustRaw.invert = function(x, y) {\n x *= 3 / 8, y *= 3 / 8;\n if (!x && abs(y) > 1) return null;\n var x2 = x * x,\n y2 = y * y,\n s = 1 + x2 + y2,\n sin3Eta = sqrt((s - sqrt(s * s - 4 * y * y)) / 2),\n eta = asin(sin3Eta) / 3,\n xi = sin3Eta ? arcosh(abs(y / sin3Eta)) / 3 : arsinh(abs(x)) / 3,\n cosEta = cos(eta),\n coshXi = cosh(xi),\n d = coshXi * coshXi - cosEta * cosEta;\n return [\n sign(x) * 2 * atan2(sinh(xi) * cosEta, 0.25 - d),\n sign(y) * 2 * atan2(coshXi * sin(eta), 0.25 + d)\n ];\n};\n\nexport default function() {\n return projection(augustRaw)\n .scale(66.1603);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/august.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, atan, cos, epsilon2, exp, halfPi, log, quarterPi, sign, sin, sqrt, sqrt2, tan} from \"./math.js\";\n\nvar sqrt8 = sqrt(8),\n phi0 = log(1 + sqrt2);\n\nexport function bakerRaw(lambda, phi) {\n var phi0 = abs(phi);\n return phi0 < quarterPi\n ? [lambda, log(tan(quarterPi + phi / 2))]\n : [lambda * cos(phi0) * (2 * sqrt2 - 1 / sin(phi0)), sign(phi) * (2 * sqrt2 * (phi0 - quarterPi) - log(tan(phi0 / 2)))];\n}\n\nbakerRaw.invert = function(x, y) {\n if ((y0 = abs(y)) < phi0) return [x, 2 * atan(exp(y)) - halfPi];\n var phi = quarterPi, i = 25, delta, y0;\n do {\n var cosPhi_2 = cos(phi / 2), tanPhi_2 = tan(phi / 2);\n phi -= delta = (sqrt8 * (phi - quarterPi) - log(tanPhi_2) - y0) / (sqrt8 - cosPhi_2 * cosPhi_2 / (2 * tanPhi_2));\n } while (abs(delta) > epsilon2 && --i > 0);\n return [x / (cos(phi) * (sqrt8 - 1 / sin(phi))), sign(y) * phi];\n};\n\nexport default function() {\n return projection(bakerRaw)\n .scale(112.314);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/baker.js","import {geoAzimuthalEqualAreaRaw as azimuthalEqualAreaRaw, geoProjectionMutator as projectionMutator} from \"d3-geo\";\nimport {asin, cos, sin} from \"./math.js\";\n\nexport function hammerRaw(A, B) {\n if (arguments.length < 2) B = A;\n if (B === 1) return azimuthalEqualAreaRaw;\n if (B === Infinity) return hammerQuarticAuthalicRaw;\n\n function forward(lambda, phi) {\n var coordinates = azimuthalEqualAreaRaw(lambda / B, phi);\n coordinates[0] *= A;\n return coordinates;\n }\n\n forward.invert = function(x, y) {\n var coordinates = azimuthalEqualAreaRaw.invert(x / A, y);\n coordinates[0] *= B;\n return coordinates;\n };\n\n return forward;\n}\n\nfunction hammerQuarticAuthalicRaw(lambda, phi) {\n return [\n lambda * cos(phi) / cos(phi /= 2),\n 2 * sin(phi)\n ];\n}\n\nhammerQuarticAuthalicRaw.invert = function(x, y) {\n var phi = 2 * asin(y / 2);\n return [\n x * cos(phi / 2) / cos(phi),\n phi\n ];\n};\n\nexport default function() {\n var B = 2,\n m = projectionMutator(hammerRaw),\n p = m(B);\n\n p.coefficient = function(_) {\n if (!arguments.length) return B;\n return m(B = +_);\n };\n\n return p\n .scale(169.529);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/hammer.js","import {abs, epsilon, epsilon2} from \"./math.js\";\n\n// Approximate Newton-Raphson\n// Solve f(x) = y, start from x\nexport function solve(f, y, x) {\n var steps = 100, delta, f0, f1;\n x = x === undefined ? 0 : +x;\n y = +y;\n do {\n f0 = f(x);\n f1 = f(x + epsilon);\n if (f0 === f1) f1 = f0 + epsilon;\n x -= delta = (-1 * epsilon * (f0 - y)) / (f0 - f1);\n } while (steps-- > 0 && abs(delta) > epsilon);\n return steps < 0 ? NaN : x;\n}\n\n// Approximate Newton-Raphson in 2D\n// Solve f(a,b) = [x,y]\nexport function solve2d(f, MAX_ITERATIONS, eps) {\n if (MAX_ITERATIONS === undefined) MAX_ITERATIONS = 40;\n if (eps === undefined) eps = epsilon2;\n return function(x, y, a, b) {\n var err2, da, db;\n a = a === undefined ? 0 : +a;\n b = b === undefined ? 0 : +b;\n for (var i = 0; i < MAX_ITERATIONS; i++) {\n var p = f(a, b),\n // diffs\n tx = p[0] - x,\n ty = p[1] - y;\n if (abs(tx) < eps && abs(ty) < eps) break; // we're there!\n\n // backtrack if we overshot\n var h = tx * tx + ty * ty;\n if (h > err2) {\n a -= da /= 2;\n b -= db /= 2;\n continue;\n }\n err2 = h;\n\n // partial derivatives\n var ea = (a > 0 ? -1 : 1) * eps,\n eb = (b > 0 ? -1 : 1) * eps,\n pa = f(a + ea, b),\n pb = f(a, b + eb),\n dxa = (pa[0] - p[0]) / ea,\n dya = (pa[1] - p[1]) / ea,\n dxb = (pb[0] - p[0]) / eb,\n dyb = (pb[1] - p[1]) / eb,\n // determinant\n D = dyb * dxa - dya * dxb,\n // newton step — or half-step for small D\n l = (abs(D) < 0.5 ? 0.5 : 1) / D;\n da = (ty * dxb - tx * dyb) * l;\n db = (tx * dya - ty * dxa) * l;\n a += da;\n b += db;\n if (abs(da) < eps && abs(db) < eps) break; // we're crawling\n }\n return [a, b];\n };\n}\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/newton.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, cos, epsilon, halfPi, pi, sin, sqrt2} from \"./math.js\";\n\nexport function mollweideBromleyTheta(cp, phi) {\n var cpsinPhi = cp * sin(phi), i = 30, delta;\n do phi -= delta = (phi + sin(phi) - cpsinPhi) / (1 + cos(phi));\n while (abs(delta) > epsilon && --i > 0);\n return phi / 2;\n}\n\nexport function mollweideBromleyRaw(cx, cy, cp) {\n\n function forward(lambda, phi) {\n return [cx * lambda * cos(phi = mollweideBromleyTheta(cp, phi)), cy * sin(phi)];\n }\n\n forward.invert = function(x, y) {\n return y = asin(y / cy), [x / (cx * cos(y)), asin((2 * y + sin(2 * y)) / cp)];\n };\n\n return forward;\n}\n\nexport var mollweideRaw = mollweideBromleyRaw(sqrt2 / halfPi, sqrt2, pi);\n\nexport default function() {\n return projection(mollweideRaw)\n .scale(169.529);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mollweide.js","import {geoProjection as projection} from \"d3-geo\";\nimport {mollweideBromleyTheta} from \"./mollweide.js\";\nimport {abs, cos, epsilon, pi, quarterPi, sin, sqrt2} from \"./math.js\";\n\nvar k = 2.00276,\n w = 1.11072;\n\nexport function boggsRaw(lambda, phi) {\n var theta = mollweideBromleyTheta(pi, phi);\n return [k * lambda / (1 / cos(phi) + w / cos(theta)), (phi + sqrt2 * sin(theta)) / k];\n}\n\nboggsRaw.invert = function(x, y) {\n var ky = k * y, theta = y < 0 ? -quarterPi : quarterPi, i = 25, delta, phi;\n do {\n phi = ky - sqrt2 * sin(theta);\n theta -= delta = (sin(2 * theta) + 2 * theta - pi * sin(phi)) / (2 * cos(2 * theta) + 2 + pi * cos(phi) * sqrt2 * cos(theta));\n } while (abs(delta) > epsilon && --i > 0);\n phi = ky - sqrt2 * sin(theta);\n return [x * (1 / cos(phi) + w / cos(theta)) / k, phi];\n};\n\nexport default function() {\n return projection(boggsRaw)\n .scale(160.857);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/boggs.js","import {geoProjection as projection} from \"d3-geo\";\nimport {cos} from \"./math.js\";\n\nexport function sinusoidalRaw(lambda, phi) {\n return [lambda * cos(phi), phi];\n}\n\nsinusoidalRaw.invert = function(x, y) {\n return [x / cos(y), y];\n};\n\nexport default function() {\n return projection(sinusoidalRaw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/sinusoidal.js","import {geoProjection as projection} from \"d3-geo\";\nimport {pi} from \"./math.js\";\nimport {mollweideBromleyRaw} from \"./mollweide.js\";\n\nexport var bromleyRaw = mollweideBromleyRaw(1, 4 / pi, pi);\n\nexport default function() {\n return projection(bromleyRaw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/bromley.js","import {geoProjection as projection} from \"d3-geo\";\nimport {asin, pi, sin, sqrt, sqrtPi} from \"./math.js\";\n\nexport function collignonRaw(lambda, phi) {\n var alpha = sqrt(1 - sin(phi));\n return [(2 / sqrtPi) * lambda * alpha, sqrtPi * (1 - alpha)];\n}\n\ncollignonRaw.invert = function(x, y) {\n var lambda = (lambda = y / sqrtPi - 1) * lambda;\n return [lambda > 0 ? x * sqrt(pi / lambda) / 2 : 0, asin(1 - lambda)];\n};\n\nexport default function() {\n return projection(collignonRaw)\n .scale(95.6464)\n .center([0, 30]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/collignon.js","import {asin, atan2, cos, sin, sqrt, tan} from \"./math.js\";\nimport parallel1 from \"./parallel1.js\";\n\nexport function craigRaw(phi0) {\n var tanPhi0 = tan(phi0);\n\n function forward(lambda, phi) {\n return [lambda, (lambda ? lambda / sin(lambda) : 1) * (sin(phi) * cos(lambda) - tanPhi0 * cos(phi))];\n }\n\n forward.invert = tanPhi0 ? function(x, y) {\n if (x) y *= sin(x) / x;\n var cosLambda = cos(x);\n return [x, 2 * atan2(sqrt(cosLambda * cosLambda + tanPhi0 * tanPhi0 - y * y) - cosLambda, tanPhi0 - y)];\n } : function(x, y) {\n return [x, asin(x ? y * tan(x) / x : y)];\n };\n\n return forward;\n}\n\nexport default function() {\n return parallel1(craigRaw)\n .scale(249.828)\n .clipAngle(90);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/craig.js","import {geoProjection as projection} from \"d3-geo\";\nimport {asin, cos, sin, sqrt, sqrtPi} from \"./math.js\";\n\nvar sqrt3 = sqrt(3);\n\nexport function crasterRaw(lambda, phi) {\n return [sqrt3 * lambda * (2 * cos(2 * phi / 3) - 1) / sqrtPi, sqrt3 * sqrtPi * sin(phi / 3)];\n}\n\ncrasterRaw.invert = function(x, y) {\n var phi = 3 * asin(y / (sqrt3 * sqrtPi));\n return [sqrtPi * x / (sqrt3 * (2 * cos(2 * phi / 3) - 1)), phi];\n};\n\nexport default function() {\n return projection(crasterRaw)\n .scale(156.19);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/craster.js","import {asin, cos, sin} from \"./math.js\";\nimport parallel1 from \"./parallel1.js\";\n\nexport function cylindricalEqualAreaRaw(phi0) {\n var cosPhi0 = cos(phi0);\n\n function forward(lambda, phi) {\n return [lambda * cosPhi0, sin(phi) / cosPhi0];\n }\n\n forward.invert = function(x, y) {\n return [x / cosPhi0, asin(y * cosPhi0)];\n };\n\n return forward;\n}\n\nexport default function() {\n return parallel1(cylindricalEqualAreaRaw)\n .parallel(38.58) // acos(sqrt(width / height / pi)) * radians\n .scale(195.044); // width / (sqrt(width / height / pi) * 2 * pi)\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/cylindricalEqualArea.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, pi, sqrt} from \"./math.js\";\n\nexport function eckert1Raw(lambda, phi) {\n var alpha = sqrt(8 / (3 * pi));\n return [\n alpha * lambda * (1 - abs(phi) / pi),\n alpha * phi\n ];\n}\n\neckert1Raw.invert = function(x, y) {\n var alpha = sqrt(8 / (3 * pi)),\n phi = y / alpha;\n return [\n x / (alpha * (1 - abs(phi) / pi)),\n phi\n ];\n};\n\nexport default function() {\n return projection(eckert1Raw)\n .scale(165.664);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert1.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, pi, sign, sin, sqrt} from \"./math.js\";\n\nexport function eckert2Raw(lambda, phi) {\n var alpha = sqrt(4 - 3 * sin(abs(phi)));\n return [\n 2 / sqrt(6 * pi) * lambda * alpha,\n sign(phi) * sqrt(2 * pi / 3) * (2 - alpha)\n ];\n}\n\neckert2Raw.invert = function(x, y) {\n var alpha = 2 - abs(y) / sqrt(2 * pi / 3);\n return [\n x * sqrt(6 * pi) / (2 * alpha),\n sign(y) * asin((4 - alpha * alpha) / 3)\n ];\n};\n\nexport default function() {\n return projection(eckert2Raw)\n .scale(165.664);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert2.js","import {geoProjection as projection} from \"d3-geo\";\nimport {pi, sqrt} from \"./math.js\";\n\nexport function eckert3Raw(lambda, phi) {\n var k = sqrt(pi * (4 + pi));\n return [\n 2 / k * lambda * (1 + sqrt(1 - 4 * phi * phi / (pi * pi))),\n 4 / k * phi\n ];\n}\n\neckert3Raw.invert = function(x, y) {\n var k = sqrt(pi * (4 + pi)) / 2;\n return [\n x * k / (1 + sqrt(1 - y * y * (4 + pi) / (4 * pi))),\n y * k / 2\n ];\n};\n\nexport default function() {\n return projection(eckert3Raw)\n .scale(180.739);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert3.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, cos, epsilon, halfPi, pi, sin, sqrt} from \"./math.js\";\n\nexport function eckert4Raw(lambda, phi) {\n var k = (2 + halfPi) * sin(phi);\n phi /= 2;\n for (var i = 0, delta = Infinity; i < 10 && abs(delta) > epsilon; i++) {\n var cosPhi = cos(phi);\n phi -= delta = (phi + sin(phi) * (cosPhi + 2) - k) / (2 * cosPhi * (1 + cosPhi));\n }\n return [\n 2 / sqrt(pi * (4 + pi)) * lambda * (1 + cos(phi)),\n 2 * sqrt(pi / (4 + pi)) * sin(phi)\n ];\n}\n\neckert4Raw.invert = function(x, y) {\n var A = y * sqrt((4 + pi) / pi) / 2,\n k = asin(A),\n c = cos(k);\n return [\n x / (2 / sqrt(pi * (4 + pi)) * (1 + c)),\n asin((k + A * (c + 2)) / (2 + halfPi))\n ];\n};\n\nexport default function() {\n return projection(eckert4Raw)\n .scale(180.739);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert4.js","import {geoProjection as projection} from \"d3-geo\";\nimport {cos, pi, sqrt} from \"./math.js\";\n\nexport function eckert5Raw(lambda, phi) {\n return [\n lambda * (1 + cos(phi)) / sqrt(2 + pi),\n 2 * phi / sqrt(2 + pi)\n ];\n}\n\neckert5Raw.invert = function(x, y) {\n var k = sqrt(2 + pi),\n phi = y * k / 2;\n return [\n k * x / (1 + cos(phi)),\n phi\n ];\n};\n\nexport default function() {\n return projection(eckert5Raw)\n .scale(173.044);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert5.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, cos, epsilon, halfPi, pi, sin, sqrt} from \"./math.js\";\n\nexport function eckert6Raw(lambda, phi) {\n var k = (1 + halfPi) * sin(phi);\n for (var i = 0, delta = Infinity; i < 10 && abs(delta) > epsilon; i++) {\n phi -= delta = (phi + sin(phi) - k) / (1 + cos(phi));\n }\n k = sqrt(2 + pi);\n return [\n lambda * (1 + cos(phi)) / k,\n 2 * phi / k\n ];\n}\n\neckert6Raw.invert = function(x, y) {\n var j = 1 + halfPi,\n k = sqrt(j / 2);\n return [\n x * 2 * k / (1 + cos(y *= k)),\n asin((y + sin(y)) / j)\n ];\n};\n\nexport default function() {\n return projection(eckert6Raw)\n .scale(173.044);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eckert6.js","import {geoProjection as projection} from \"d3-geo\";\nimport {augustRaw} from \"./august.js\";\nimport {abs, atan, cos, epsilon, halfPi, log, max, min, sin, sqrt, sqrt1_2, sqrt2} from \"./math.js\";\n\nvar eisenlohrK = 3 + 2 * sqrt2;\n\nexport function eisenlohrRaw(lambda, phi) {\n var s0 = sin(lambda /= 2),\n c0 = cos(lambda),\n k = sqrt(cos(phi)),\n c1 = cos(phi /= 2),\n t = sin(phi) / (c1 + sqrt2 * c0 * k),\n c = sqrt(2 / (1 + t * t)),\n v = sqrt((sqrt2 * c1 + (c0 + s0) * k) / (sqrt2 * c1 + (c0 - s0) * k));\n return [\n eisenlohrK * (c * (v - 1 / v) - 2 * log(v)),\n eisenlohrK * (c * t * (v + 1 / v) - 2 * atan(t))\n ];\n}\n\neisenlohrRaw.invert = function(x, y) {\n if (!(p = augustRaw.invert(x / 1.2, y * 1.065))) return null;\n var lambda = p[0], phi = p[1], i = 20, p;\n x /= eisenlohrK, y /= eisenlohrK;\n do {\n var _0 = lambda / 2,\n _1 = phi / 2,\n s0 = sin(_0),\n c0 = cos(_0),\n s1 = sin(_1),\n c1 = cos(_1),\n cos1 = cos(phi),\n k = sqrt(cos1),\n t = s1 / (c1 + sqrt2 * c0 * k),\n t2 = t * t,\n c = sqrt(2 / (1 + t2)),\n v0 = (sqrt2 * c1 + (c0 + s0) * k),\n v1 = (sqrt2 * c1 + (c0 - s0) * k),\n v2 = v0 / v1,\n v = sqrt(v2),\n vm1v = v - 1 / v,\n vp1v = v + 1 / v,\n fx = c * vm1v - 2 * log(v) - x,\n fy = c * t * vp1v - 2 * atan(t) - y,\n deltatDeltaLambda = s1 && sqrt1_2 * k * s0 * t2 / s1,\n deltatDeltaPhi = (sqrt2 * c0 * c1 + k) / (2 * (c1 + sqrt2 * c0 * k) * (c1 + sqrt2 * c0 * k) * k),\n deltacDeltat = -0.5 * t * c * c * c,\n deltacDeltaLambda = deltacDeltat * deltatDeltaLambda,\n deltacDeltaPhi = deltacDeltat * deltatDeltaPhi,\n A = (A = 2 * c1 + sqrt2 * k * (c0 - s0)) * A * v,\n deltavDeltaLambda = (sqrt2 * c0 * c1 * k + cos1) / A,\n deltavDeltaPhi = -(sqrt2 * s0 * s1) / (k * A),\n deltaxDeltaLambda = vm1v * deltacDeltaLambda - 2 * deltavDeltaLambda / v + c * (deltavDeltaLambda + deltavDeltaLambda / v2),\n deltaxDeltaPhi = vm1v * deltacDeltaPhi - 2 * deltavDeltaPhi / v + c * (deltavDeltaPhi + deltavDeltaPhi / v2),\n deltayDeltaLambda = t * vp1v * deltacDeltaLambda - 2 * deltatDeltaLambda / (1 + t2) + c * vp1v * deltatDeltaLambda + c * t * (deltavDeltaLambda - deltavDeltaLambda / v2),\n deltayDeltaPhi = t * vp1v * deltacDeltaPhi - 2 * deltatDeltaPhi / (1 + t2) + c * vp1v * deltatDeltaPhi + c * t * (deltavDeltaPhi - deltavDeltaPhi / v2),\n denominator = deltaxDeltaPhi * deltayDeltaLambda - deltayDeltaPhi * deltaxDeltaLambda;\n if (!denominator) break;\n var deltaLambda = (fy * deltaxDeltaPhi - fx * deltayDeltaPhi) / denominator,\n deltaPhi = (fx * deltayDeltaLambda - fy * deltaxDeltaLambda) / denominator;\n lambda -= deltaLambda;\n phi = max(-halfPi, min(halfPi, phi - deltaPhi));\n } while ((abs(deltaLambda) > epsilon || abs(deltaPhi) > epsilon) && --i > 0);\n return abs(abs(phi) - halfPi) < epsilon ? [0, phi] : i && [lambda, phi];\n};\n\nexport default function() {\n return projection(eisenlohrRaw)\n .scale(62.5271);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/eisenlohr.js","import {geoProjection as projection} from \"d3-geo\";\nimport {atan, cos, radians, sqrt, tan} from \"./math.js\";\n\nvar faheyK = cos(35 * radians);\n\nexport function faheyRaw(lambda, phi) {\n var t = tan(phi / 2);\n return [lambda * faheyK * sqrt(1 - t * t), (1 + faheyK) * t];\n}\n\nfaheyRaw.invert = function(x, y) {\n var t = y / (1 + faheyK);\n return [x && x / (faheyK * sqrt(1 - t * t)), 2 * atan(t)];\n};\n\nexport default function() {\n return projection(faheyRaw)\n .scale(137.152);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/fahey.js","import {geoProjection as projection} from \"d3-geo\";\nimport {atan, cos, sqrtPi, tan} from \"./math.js\";\n\nexport function foucautRaw(lambda, phi) {\n var k = phi / 2, cosk = cos(k);\n return [ 2 * lambda / sqrtPi * cos(phi) * cosk * cosk, sqrtPi * tan(k)];\n}\n\nfoucautRaw.invert = function(x, y) {\n var k = atan(y / sqrtPi), cosk = cos(k), phi = 2 * k;\n return [x * sqrtPi / 2 / (cos(phi) * cosk * cosk), phi];\n};\n\nexport default function() {\n return projection(foucautRaw)\n .scale(135.264);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/foucaut.js","import {geoAzimuthalEquidistantRaw as azimuthalEquidistantRaw, geoProjectionMutator as projectionMutator} from \"d3-geo\";\nimport {abs, asin, atan2, cos, degrees, epsilon, epsilon2, halfPi, pi, radians, round, sin, sqrt} from \"./math.js\";\n\nexport function gingeryRaw(rho, n) {\n var k = 2 * pi / n,\n rho2 = rho * rho;\n\n function forward(lambda, phi) {\n var p = azimuthalEquidistantRaw(lambda, phi),\n x = p[0],\n y = p[1],\n r2 = x * x + y * y;\n\n if (r2 > rho2) {\n var r = sqrt(r2),\n theta = atan2(y, x),\n theta0 = k * round(theta / k),\n alpha = theta - theta0,\n rhoCosAlpha = rho * cos(alpha),\n k_ = (rho * sin(alpha) - alpha * sin(rhoCosAlpha)) / (halfPi - rhoCosAlpha),\n s_ = gingeryLength(alpha, k_),\n e = (pi - rho) / gingeryIntegrate(s_, rhoCosAlpha, pi);\n\n x = r;\n var i = 50, delta;\n do {\n x -= delta = (rho + gingeryIntegrate(s_, rhoCosAlpha, x) * e - r) / (s_(x) * e);\n } while (abs(delta) > epsilon && --i > 0);\n\n y = alpha * sin(x);\n if (x < halfPi) y -= k_ * (x - halfPi);\n\n var s = sin(theta0),\n c = cos(theta0);\n p[0] = x * c - y * s;\n p[1] = x * s + y * c;\n }\n return p;\n }\n\n forward.invert = function(x, y) {\n var r2 = x * x + y * y;\n if (r2 > rho2) {\n var r = sqrt(r2),\n theta = atan2(y, x),\n theta0 = k * round(theta / k),\n dTheta = theta - theta0;\n\n x = r * cos(dTheta);\n y = r * sin(dTheta);\n\n var x_halfPi = x - halfPi,\n sinx = sin(x),\n alpha = y / sinx,\n delta = x < halfPi ? Infinity : 0,\n i = 10;\n\n while (true) {\n var rhosinAlpha = rho * sin(alpha),\n rhoCosAlpha = rho * cos(alpha),\n sinRhoCosAlpha = sin(rhoCosAlpha),\n halfPi_RhoCosAlpha = halfPi - rhoCosAlpha,\n k_ = (rhosinAlpha - alpha * sinRhoCosAlpha) / halfPi_RhoCosAlpha,\n s_ = gingeryLength(alpha, k_);\n\n if (abs(delta) < epsilon2 || !--i) break;\n\n alpha -= delta = (alpha * sinx - k_ * x_halfPi - y) / (\n sinx - x_halfPi * 2 * (\n halfPi_RhoCosAlpha * (rhoCosAlpha + alpha * rhosinAlpha * cos(rhoCosAlpha) - sinRhoCosAlpha) -\n rhosinAlpha * (rhosinAlpha - alpha * sinRhoCosAlpha)\n ) / (halfPi_RhoCosAlpha * halfPi_RhoCosAlpha));\n }\n r = rho + gingeryIntegrate(s_, rhoCosAlpha, x) * (pi - rho) / gingeryIntegrate(s_, rhoCosAlpha, pi);\n theta = theta0 + alpha;\n x = r * cos(theta);\n y = r * sin(theta);\n }\n return azimuthalEquidistantRaw.invert(x, y);\n };\n\n return forward;\n}\n\nfunction gingeryLength(alpha, k) {\n return function(x) {\n var y_ = alpha * cos(x);\n if (x < halfPi) y_ -= k;\n return sqrt(1 + y_ * y_);\n };\n}\n\n// Numerical integration: trapezoidal rule.\nfunction gingeryIntegrate(f, a, b) {\n var n = 50,\n h = (b - a) / n,\n s = f(a) + f(b);\n for (var i = 1, x = a; i < n; ++i) s += 2 * f(x += h);\n return s * 0.5 * h;\n}\n\nexport default function() {\n var n = 6,\n rho = 30 * radians,\n cRho = cos(rho),\n sRho = sin(rho),\n m = projectionMutator(gingeryRaw),\n p = m(rho, n),\n stream_ = p.stream,\n epsilon = 1e-2,\n cr = -cos(epsilon * radians),\n sr = sin(epsilon * radians);\n\n p.radius = function(_) {\n if (!arguments.length) return rho * degrees;\n cRho = cos(rho = _ * radians);\n sRho = sin(rho);\n return m(rho, n);\n };\n\n p.lobes = function(_) {\n if (!arguments.length) return n;\n return m(rho, n = +_);\n };\n\n p.stream = function(stream) {\n var rotate = p.rotate(),\n rotateStream = stream_(stream),\n sphereStream = (p.rotate([0, 0]), stream_(stream));\n p.rotate(rotate);\n rotateStream.sphere = function() {\n sphereStream.polygonStart(), sphereStream.lineStart();\n for (var i = 0, delta = 2 * pi / n, phi = 0; i < n; ++i, phi -= delta) {\n sphereStream.point(atan2(sr * cos(phi), cr) * degrees, asin(sr * sin(phi)) * degrees);\n sphereStream.point(atan2(sRho * cos(phi - delta / 2), cRho) * degrees, asin(sRho * sin(phi - delta / 2)) * degrees);\n }\n sphereStream.lineEnd(), sphereStream.polygonEnd();\n };\n return rotateStream;\n };\n\n return p\n .rotate([90, -40])\n .scale(91.7095)\n .clipAngle(180 - 1e-3);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/gingery.js","import {abs, asin, cos, epsilon, pi, sin, sqrt} from \"./math.js\";\n\nexport default function(a, b, c, d, e, f, g, h) {\n if (arguments.length < 8) h = 0;\n\n function forward(lambda, phi) {\n if (!phi) return [a * lambda / pi, 0];\n var phi2 = phi * phi,\n xB = a + phi2 * (b + phi2 * (c + phi2 * d)),\n yB = phi * (e - 1 + phi2 * (f - h + phi2 * g)),\n m = (xB * xB + yB * yB) / (2 * yB),\n alpha = lambda * asin(xB / m) / pi;\n return [m * sin(alpha), phi * (1 + phi2 * h) + m * (1 - cos(alpha))];\n }\n\n forward.invert = function(x, y) {\n var lambda = pi * x / a,\n phi = y,\n deltaLambda, deltaPhi, i = 50;\n do {\n var phi2 = phi * phi,\n xB = a + phi2 * (b + phi2 * (c + phi2 * d)),\n yB = phi * (e - 1 + phi2 * (f - h + phi2 * g)),\n p = xB * xB + yB * yB,\n q = 2 * yB,\n m = p / q,\n m2 = m * m,\n dAlphadLambda = asin(xB / m) / pi,\n alpha = lambda * dAlphadLambda,\n xB2 = xB * xB,\n dxBdPhi = (2 * b + phi2 * (4 * c + phi2 * 6 * d)) * phi,\n dyBdPhi = e + phi2 * (3 * f + phi2 * 5 * g),\n dpdPhi = 2 * (xB * dxBdPhi + yB * (dyBdPhi - 1)),\n dqdPhi = 2 * (dyBdPhi - 1),\n dmdPhi = (dpdPhi * q - p * dqdPhi) / (q * q),\n cosAlpha = cos(alpha),\n sinAlpha = sin(alpha),\n mcosAlpha = m * cosAlpha,\n msinAlpha = m * sinAlpha,\n dAlphadPhi = ((lambda / pi) * (1 / sqrt(1 - xB2 / m2)) * (dxBdPhi * m - xB * dmdPhi)) / m2,\n fx = msinAlpha - x,\n fy = phi * (1 + phi2 * h) + m - mcosAlpha - y,\n deltaxDeltaPhi = dmdPhi * sinAlpha + mcosAlpha * dAlphadPhi,\n deltaxDeltaLambda = mcosAlpha * dAlphadLambda,\n deltayDeltaPhi = 1 + dmdPhi - (dmdPhi * cosAlpha - msinAlpha * dAlphadPhi),\n deltayDeltaLambda = msinAlpha * dAlphadLambda,\n denominator = deltaxDeltaPhi * deltayDeltaLambda - deltayDeltaPhi * deltaxDeltaLambda;\n if (!denominator) break;\n lambda -= deltaLambda = (fy * deltaxDeltaPhi - fx * deltayDeltaPhi) / denominator;\n phi -= deltaPhi = (fx * deltayDeltaLambda - fy * deltaxDeltaLambda) / denominator;\n } while ((abs(deltaLambda) > epsilon || abs(deltaPhi) > epsilon) && --i > 0);\n return [lambda, phi];\n };\n\n return forward;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburgPolyconic.js","import {geoProjection as projection} from \"d3-geo\";\nimport ginzburgPolyconicRaw from \"./ginzburgPolyconic.js\";\n\nexport var ginzburg4Raw = ginzburgPolyconicRaw(2.8284, -1.6988, 0.75432, -0.18071, 1.76003, -0.38914, 0.042555);\n\nexport default function() {\n return projection(ginzburg4Raw)\n .scale(149.995);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg4.js","import {geoProjection as projection} from \"d3-geo\";\nimport ginzburgPolyconicRaw from \"./ginzburgPolyconic.js\";\n\nexport var ginzburg5Raw = ginzburgPolyconicRaw(2.583819, -0.835827, 0.170354, -0.038094, 1.543313, -0.411435,0.082742);\n\nexport default function() {\n return projection(ginzburg5Raw)\n .scale(153.93);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg5.js","import {geoProjection as projection} from \"d3-geo\";\nimport ginzburgPolyconicRaw from \"./ginzburgPolyconic.js\";\nimport {pi} from \"./math.js\";\n\nexport var ginzburg6Raw = ginzburgPolyconicRaw(5 / 6 * pi, -0.62636, -0.0344, 0, 1.3493, -0.05524, 0, 0.045);\n\nexport default function() {\n return projection(ginzburg6Raw)\n .scale(130.945);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg6.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, epsilon} from \"./math.js\";\n\nexport function ginzburg8Raw(lambda, phi) {\n var lambda2 = lambda * lambda,\n phi2 = phi * phi;\n return [\n lambda * (1 - 0.162388 * phi2) * (0.87 - 0.000952426 * lambda2 * lambda2),\n phi * (1 + phi2 / 12)\n ];\n}\n\nginzburg8Raw.invert = function(x, y) {\n var lambda = x,\n phi = y,\n i = 50, delta;\n do {\n var phi2 = phi * phi;\n phi -= delta = (phi * (1 + phi2 / 12) - y) / (1 + phi2 / 4);\n } while (abs(delta) > epsilon && --i > 0);\n i = 50;\n x /= 1 -0.162388 * phi2;\n do {\n var lambda4 = (lambda4 = lambda * lambda) * lambda4;\n lambda -= delta = (lambda * (0.87 - 0.000952426 * lambda4) - x) / (0.87 - 0.00476213 * lambda4);\n } while (abs(delta) > epsilon && --i > 0);\n return [lambda, phi];\n};\n\nexport default function() {\n return projection(ginzburg8Raw)\n .scale(131.747);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg8.js","import {geoProjection as projection} from \"d3-geo\";\nimport ginzburgPolyconicRaw from \"./ginzburgPolyconic.js\";\n\nexport var ginzburg9Raw = ginzburgPolyconicRaw(2.6516, -0.76534, 0.19123, -0.047094, 1.36289, -0.13965,0.031762);\n\nexport default function() {\n return projection(ginzburg9Raw)\n .scale(131.087);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/ginzburg9.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, atan2, cos, sign, epsilon, epsilon2, halfPi, pi, sin, sqrt} from \"./math.js\";\nimport squareRaw from \"./square.js\";\n\nexport function gringortenRaw(lambda, phi) {\n var sLambda = sign(lambda),\n sPhi = sign(phi),\n cosPhi = cos(phi),\n x = cos(lambda) * cosPhi,\n y = sin(lambda) * cosPhi,\n z = sin(sPhi * phi);\n lambda = abs(atan2(y, z));\n phi = asin(x);\n if (abs(lambda - halfPi) > epsilon) lambda %= halfPi;\n var point = gringortenHexadecant(lambda > pi / 4 ? halfPi - lambda : lambda, phi);\n if (lambda > pi / 4) z = point[0], point[0] = -point[1], point[1] = -z;\n return (point[0] *= sLambda, point[1] *= -sPhi, point);\n}\n\ngringortenRaw.invert = function(x, y) {\n if (abs(x) > 1) x = sign(x) * 2 - x;\n if (abs(y) > 1) y = sign(y) * 2 - y;\n var sx = sign(x),\n sy = sign(y),\n x0 = -sx * x,\n y0 = -sy * y,\n t = y0 / x0 < 1,\n p = gringortenHexadecantInvert(t ? y0 : x0, t ? x0 : y0),\n lambda = p[0],\n phi = p[1],\n cosPhi = cos(phi);\n if (t) lambda = -halfPi - lambda;\n return [sx * (atan2(sin(lambda) * cosPhi, -sin(phi)) + pi), sy * asin(cos(lambda) * cosPhi)];\n};\n\nfunction gringortenHexadecant(lambda, phi) {\n if (phi === halfPi) return [0, 0];\n\n var sinPhi = sin(phi),\n r = sinPhi * sinPhi,\n r2 = r * r,\n j = 1 + r2,\n k = 1 + 3 * r2,\n q = 1 - r2,\n z = asin(1 / sqrt(j)),\n v = q + r * j * z,\n p2 = (1 - sinPhi) / v,\n p = sqrt(p2),\n a2 = p2 * j,\n a = sqrt(a2),\n h = p * q,\n x,\n i;\n\n if (lambda === 0) return [0, -(h + r * a)];\n\n var cosPhi = cos(phi),\n secPhi = 1 / cosPhi,\n drdPhi = 2 * sinPhi * cosPhi,\n dvdPhi = (-3 * r + z * k) * drdPhi,\n dp2dPhi = (-v * cosPhi - (1 - sinPhi) * dvdPhi) / (v * v),\n dpdPhi = (0.5 * dp2dPhi) / p,\n dhdPhi = q * dpdPhi - 2 * r * p * drdPhi,\n dra2dPhi = r * j * dp2dPhi + p2 * k * drdPhi,\n mu = -secPhi * drdPhi,\n nu = -secPhi * dra2dPhi,\n zeta = -2 * secPhi * dhdPhi,\n lambda1 = 4 * lambda / pi,\n delta;\n\n // Slower but accurate bisection method.\n if (lambda > 0.222 * pi || phi < pi / 4 && lambda > 0.175 * pi) {\n x = (h + r * sqrt(a2 * (1 + r2) - h * h)) / (1 + r2);\n if (lambda > pi / 4) return [x, x];\n var x1 = x, x0 = 0.5 * x;\n x = 0.5 * (x0 + x1), i = 50;\n do {\n var g = sqrt(a2 - x * x),\n f = (x * (zeta + mu * g) + nu * asin(x / a)) - lambda1;\n if (!f) break;\n if (f < 0) x0 = x;\n else x1 = x;\n x = 0.5 * (x0 + x1);\n } while (abs(x1 - x0) > epsilon && --i > 0);\n }\n\n // Newton-Raphson.\n else {\n x = epsilon, i = 25;\n do {\n var x2 = x * x,\n g2 = sqrt(a2 - x2),\n zetaMug = zeta + mu * g2,\n f2 = x * zetaMug + nu * asin(x / a) - lambda1,\n df = zetaMug + (nu - mu * x2) / g2;\n x -= delta = g2 ? f2 / df : 0;\n } while (abs(delta) > epsilon && --i > 0);\n }\n\n return [x, -h - r * sqrt(a2 - x * x)];\n}\n\nfunction gringortenHexadecantInvert(x, y) {\n var x0 = 0,\n x1 = 1,\n r = 0.5,\n i = 50;\n\n while (true) {\n var r2 = r * r,\n sinPhi = sqrt(r),\n z = asin(1 / sqrt(1 + r2)),\n v = (1 - r2) + r * (1 + r2) * z,\n p2 = (1 - sinPhi) / v,\n p = sqrt(p2),\n a2 = p2 * (1 + r2),\n h = p * (1 - r2),\n g2 = a2 - x * x,\n g = sqrt(g2),\n y0 = y + h + r * g;\n if (abs(x1 - x0) < epsilon2 || --i === 0 || y0 === 0) break;\n if (y0 > 0) x0 = r;\n else x1 = r;\n r = 0.5 * (x0 + x1);\n }\n\n if (!i) return null;\n\n var phi = asin(sinPhi),\n cosPhi = cos(phi),\n secPhi = 1 / cosPhi,\n drdPhi = 2 * sinPhi * cosPhi,\n dvdPhi = (-3 * r + z * (1 + 3 * r2)) * drdPhi,\n dp2dPhi = (-v * cosPhi - (1 - sinPhi) * dvdPhi) / (v * v),\n dpdPhi = 0.5 * dp2dPhi / p,\n dhdPhi = (1 - r2) * dpdPhi - 2 * r * p * drdPhi,\n zeta = -2 * secPhi * dhdPhi,\n mu = -secPhi * drdPhi,\n nu = -secPhi * (r * (1 + r2) * dp2dPhi + p2 * (1 + 3 * r2) * drdPhi);\n\n return [pi / 4 * (x * (zeta + mu * g) + nu * asin(x / sqrt(a2))), phi];\n}\n\nexport default function() {\n return projection(squareRaw(gringortenRaw))\n .scale(239.75);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/gringorten.js","import {abs, asin, atan, cos, cosh, epsilon, exp, halfPi, log, pi, pow, quarterPi, sign, sin, sinh, sqrt, tan, tanh} from \"./math.js\";\n\n// Returns [sn, cn, dn](u + iv|m).\nexport function ellipticJi(u, v, m) {\n var a, b, c;\n if (!u) {\n b = ellipticJ(v, 1 - m);\n return [\n [0, b[0] / b[1]],\n [1 / b[1], 0],\n [b[2] / b[1], 0]\n ];\n }\n a = ellipticJ(u, m);\n if (!v) return [[a[0], 0], [a[1], 0], [a[2], 0]];\n b = ellipticJ(v, 1 - m);\n c = b[1] * b[1] + m * a[0] * a[0] * b[0] * b[0];\n return [\n [a[0] * b[2] / c, a[1] * a[2] * b[0] * b[1] / c],\n [a[1] * b[1] / c, -a[0] * a[2] * b[0] * b[2] / c],\n [a[2] * b[1] * b[2] / c, -m * a[0] * a[1] * b[0] / c]\n ];\n}\n\n// Returns [sn, cn, dn, ph](u|m).\nexport function ellipticJ(u, m) {\n var ai, b, phi, t, twon;\n if (m < epsilon) {\n t = sin(u);\n b = cos(u);\n ai = m * (u - t * b) / 4;\n return [\n t - ai * b,\n b + ai * t,\n 1 - m * t * t / 2,\n u - ai\n ];\n }\n if (m >= 1 - epsilon) {\n ai = (1 - m) / 4;\n b = cosh(u);\n t = tanh(u);\n phi = 1 / b;\n twon = b * sinh(u);\n return [\n t + ai * (twon - u) / (b * b),\n phi - ai * t * phi * (twon - u),\n phi + ai * t * phi * (twon + u),\n 2 * atan(exp(u)) - halfPi + ai * (twon - u) / b\n ];\n }\n\n var a = [1, 0, 0, 0, 0, 0, 0, 0, 0],\n c = [sqrt(m), 0, 0, 0, 0, 0, 0, 0, 0],\n i = 0;\n b = sqrt(1 - m);\n twon = 1;\n\n while (abs(c[i] / a[i]) > epsilon && i < 8) {\n ai = a[i++];\n c[i] = (ai - b) / 2;\n a[i] = (ai + b) / 2;\n b = sqrt(ai * b);\n twon *= 2;\n }\n\n phi = twon * a[i] * u;\n do {\n t = c[i] * sin(b = phi) / a[i];\n phi = (asin(t) + phi) / 2;\n } while (--i);\n\n return [sin(phi), t = cos(phi), t / cos(phi - b), phi];\n}\n\n// Calculate F(phi+iPsi|m).\n// See Abramowitz and Stegun, 17.4.11.\nexport function ellipticFi(phi, psi, m) {\n var r = abs(phi),\n i = abs(psi),\n sinhPsi = sinh(i);\n if (r) {\n var cscPhi = 1 / sin(r),\n cotPhi2 = 1 / (tan(r) * tan(r)),\n b = -(cotPhi2 + m * (sinhPsi * sinhPsi * cscPhi * cscPhi) - 1 + m),\n c = (m - 1) * cotPhi2,\n cotLambda2 = (-b + sqrt(b * b - 4 * c)) / 2;\n return [\n ellipticF(atan(1 / sqrt(cotLambda2)), m) * sign(phi),\n ellipticF(atan(sqrt((cotLambda2 / cotPhi2 - 1) / m)), 1 - m) * sign(psi)\n ];\n }\n return [\n 0,\n ellipticF(atan(sinhPsi), 1 - m) * sign(psi)\n ];\n}\n\n// Calculate F(phi|m) where m = k² = sin²α.\n// See Abramowitz and Stegun, 17.6.7.\nexport function ellipticF(phi, m) {\n if (!m) return phi;\n if (m === 1) return log(tan(phi / 2 + quarterPi));\n var a = 1,\n b = sqrt(1 - m),\n c = sqrt(m);\n for (var i = 0; abs(c) > epsilon; i++) {\n if (phi % pi) {\n var dPhi = atan(b * tan(phi) / a);\n if (dPhi < 0) dPhi += pi;\n phi += dPhi + ~~(phi / pi) * pi;\n } else phi += phi;\n c = (a + b) / 2;\n b = sqrt(a * b);\n c = ((a = c) - b) / 2;\n }\n return phi / (pow(2, i) * a);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/elliptic.js","import {geoProjection as projection} from \"d3-geo\";\nimport {ellipticF, ellipticFi, ellipticJi} from \"./elliptic.js\";\nimport {abs, atan, atan2, cos, exp, halfPi, log, pi, sin, sqrt, sqrt2, tan} from \"./math.js\";\nimport squareRaw from \"./square.js\";\n\nexport function guyouRaw(lambda, phi) {\n var k_ = (sqrt2 - 1) / (sqrt2 + 1),\n k = sqrt(1 - k_ * k_),\n K = ellipticF(halfPi, k * k),\n f = -1,\n psi = log(tan(pi / 4 + abs(phi) / 2)),\n r = exp(f * psi) / sqrt(k_),\n at = guyouComplexAtan(r * cos(f * lambda), r * sin(f * lambda)),\n t = ellipticFi(at[0], at[1], k * k);\n return [-t[1], (phi >= 0 ? 1 : -1) * (0.5 * K - t[0])];\n}\n\nfunction guyouComplexAtan(x, y) {\n var x2 = x * x,\n y_1 = y + 1,\n t = 1 - x2 - y * y;\n return [\n 0.5 * ((x >= 0 ? halfPi : -halfPi) - atan2(t, 2 * x)),\n -0.25 * log(t * t + 4 * x2) +0.5 * log(y_1 * y_1 + x2)\n ];\n}\n\nfunction guyouComplexDivide(a, b) {\n var denominator = b[0] * b[0] + b[1] * b[1];\n return [\n (a[0] * b[0] + a[1] * b[1]) / denominator,\n (a[1] * b[0] - a[0] * b[1]) / denominator\n ];\n}\n\nguyouRaw.invert = function(x, y) {\n var k_ = (sqrt2 - 1) / (sqrt2 + 1),\n k = sqrt(1 - k_ * k_),\n K = ellipticF(halfPi, k * k),\n f = -1,\n j = ellipticJi(0.5 * K - y, -x, k * k),\n tn = guyouComplexDivide(j[0], j[1]),\n lambda = atan2(tn[1], tn[0]) / f;\n return [\n lambda,\n 2 * atan(exp(0.5 / f * log(k_ * tn[0] * tn[0] + k_ * tn[1] * tn[1]))) - halfPi\n ];\n};\n\nexport default function() {\n return projection(squareRaw(guyouRaw))\n .scale(151.496);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/guyou.js","import {range} from \"d3-array\";\nimport {geoStream, geoProjectionMutator as projectionMutator} from \"d3-geo\";\nimport {collignonRaw} from \"./collignon.js\";\nimport {cylindricalEqualAreaRaw} from \"./cylindricalEqualArea.js\";\nimport {abs, asin, degrees, epsilon, floor, max, min, pi, radians, sqrtPi, tau} from \"./math.js\";\n\nvar K = 3,\n healpixParallel = asin(1 - 1 / K) * degrees,\n healpixLambert = cylindricalEqualAreaRaw(0);\n\nexport function healpixRaw(H) {\n var phi0 = healpixParallel * radians,\n dx = collignonRaw(pi, phi0)[0] - collignonRaw(-pi, phi0)[0],\n y0 = healpixLambert(0, phi0)[1],\n y1 = collignonRaw(0, phi0)[1],\n dy1 = sqrtPi - y1,\n k = tau / H,\n w = 4 / tau,\n h = y0 + (dy1 * dy1 * 4) / tau;\n\n function forward(lambda, phi) {\n var point,\n phi2 = abs(phi);\n if (phi2 > phi0) {\n var i = min(H - 1, max(0, floor((lambda + pi) / k)));\n lambda += pi * (H - 1) / H - i * k;\n point = collignonRaw(lambda, phi2);\n point[0] = point[0] * tau / dx - tau * (H - 1) / (2 * H) + i * tau / H;\n point[1] = y0 + (point[1] - y1) * 4 * dy1 / tau;\n if (phi < 0) point[1] = -point[1];\n } else {\n point = healpixLambert(lambda, phi);\n }\n point[0] *= w, point[1] /= h;\n return point;\n }\n\n forward.invert = function(x, y) {\n x /= w, y *= h;\n var y2 = abs(y);\n if (y2 > y0) {\n var i = min(H - 1, max(0, floor((x + pi) / k)));\n x = (x + pi * (H - 1) / H - i * k) * dx / tau;\n var point = collignonRaw.invert(x, 0.25 * (y2 - y0) * tau / dy1 + y1);\n point[0] -= pi * (H - 1) / H - i * k;\n if (y < 0) point[1] = -point[1];\n return point;\n }\n return healpixLambert.invert(x, y);\n };\n\n return forward;\n}\n\nfunction sphereTop(x, i) {\n return [x, i & 1 ? 90 - epsilon : healpixParallel];\n}\n\nfunction sphereBottom(x, i) {\n return [x, i & 1 ? -90 + epsilon : -healpixParallel];\n}\n\nfunction sphereNudge(d) {\n return [d[0] * (1 - epsilon), d[1]];\n}\n\nfunction sphere(step) {\n var c = [].concat(\n range(-180, 180 + step / 2, step).map(sphereTop),\n range(180, -180 - step / 2, -step).map(sphereBottom)\n );\n return {\n type: \"Polygon\",\n coordinates: [step === 180 ? c.map(sphereNudge) : c]\n };\n}\n\nexport default function() {\n var H = 4,\n m = projectionMutator(healpixRaw),\n p = m(H),\n stream_ = p.stream;\n\n p.lobes = function(_) {\n return arguments.length ? m(H = +_) : H;\n };\n\n p.stream = function(stream) {\n var rotate = p.rotate(),\n rotateStream = stream_(stream),\n sphereStream = (p.rotate([0, 0]), stream_(stream));\n p.rotate(rotate);\n rotateStream.sphere = function() { geoStream(sphere(180 / H), sphereStream); };\n return rotateStream;\n };\n\n return p\n .scale(239.75);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/healpix.js","import {geoProjectionMutator as projectionMutator} from \"d3-geo\";\nimport {abs, acos, asin, atan2, cos, epsilon2, halfPi, pi, sin, sqrt} from \"./math.js\";\n\nexport function hillRaw(K) {\n var L = 1 + K,\n sinBt = sin(1 / L),\n Bt = asin(sinBt),\n A = 2 * sqrt(pi / (B = pi + 4 * Bt * L)),\n B,\n rho0 = 0.5 * A * (L + sqrt(K * (2 + K))),\n K2 = K * K,\n L2 = L * L;\n\n function forward(lambda, phi) {\n var t = 1 - sin(phi),\n rho,\n omega;\n if (t && t < 2) {\n var theta = halfPi - phi, i = 25, delta;\n do {\n var sinTheta = sin(theta),\n cosTheta = cos(theta),\n Bt_Bt1 = Bt + atan2(sinTheta, L - cosTheta),\n C = 1 + L2 - 2 * L * cosTheta;\n theta -= delta = (theta - K2 * Bt - L * sinTheta + C * Bt_Bt1 -0.5 * t * B) / (2 * L * sinTheta * Bt_Bt1);\n } while (abs(delta) > epsilon2 && --i > 0);\n rho = A * sqrt(C);\n omega = lambda * Bt_Bt1 / pi;\n } else {\n rho = A * (K + t);\n omega = lambda * Bt / pi;\n }\n return [\n rho * sin(omega),\n rho0 - rho * cos(omega)\n ];\n }\n\n forward.invert = function(x, y) {\n var rho2 = x * x + (y -= rho0) * y,\n cosTheta = (1 + L2 - rho2 / (A * A)) / (2 * L),\n theta = acos(cosTheta),\n sinTheta = sin(theta),\n Bt_Bt1 = Bt + atan2(sinTheta, L - cosTheta);\n return [\n asin(x / sqrt(rho2)) * pi / Bt_Bt1,\n asin(1 - 2 * (theta - K2 * Bt - L * sinTheta + (1 + L2 - 2 * L * cosTheta) * Bt_Bt1) / B)\n ];\n };\n\n return forward;\n}\n\nexport default function() {\n var K = 1,\n m = projectionMutator(hillRaw),\n p = m(K);\n\n p.ratio = function(_) {\n return arguments.length ? m(K = +_) : K;\n };\n\n return p\n .scale(167.774)\n .center([0, 18.67]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/hill.js","import {geoProjection as projection} from \"d3-geo\";\nimport {mollweideRaw} from \"./mollweide.js\";\nimport {sinusoidalRaw} from \"./sinusoidal.js\";\n\nexport var sinuMollweidePhi = 0.7109889596207567;\n\nexport var sinuMollweideY = 0.0528035274542;\n\nexport function sinuMollweideRaw(lambda, phi) {\n return phi > -sinuMollweidePhi\n ? (lambda = mollweideRaw(lambda, phi), lambda[1] += sinuMollweideY, lambda)\n : sinusoidalRaw(lambda, phi);\n}\n\nsinuMollweideRaw.invert = function(x, y) {\n return y > -sinuMollweidePhi\n ? mollweideRaw.invert(x, y - sinuMollweideY)\n : sinusoidalRaw.invert(x, y);\n};\n\nexport default function() {\n return projection(sinuMollweideRaw)\n .rotate([-20, -55])\n .scale(164.263)\n .center([0, -5.4036]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/sinuMollweide.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs} from \"./math.js\";\nimport {mollweideRaw} from \"./mollweide.js\";\nimport {sinusoidalRaw} from \"./sinusoidal.js\";\nimport {sinuMollweidePhi, sinuMollweideY} from \"./sinuMollweide.js\";\n\nexport function homolosineRaw(lambda, phi) {\n return abs(phi) > sinuMollweidePhi\n ? (lambda = mollweideRaw(lambda, phi), lambda[1] -= phi > 0 ? sinuMollweideY : -sinuMollweideY, lambda)\n : sinusoidalRaw(lambda, phi);\n}\n\nhomolosineRaw.invert = function(x, y) {\n return abs(y) > sinuMollweidePhi\n ? mollweideRaw.invert(x, y + (y > 0 ? sinuMollweideY : -sinuMollweideY))\n : sinusoidalRaw.invert(x, y);\n};\n\nexport default function() {\n return projection(homolosineRaw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/homolosine.js","import {geoProjection as projection} from \"d3-geo\";\nimport {pi, sqrt, tau} from \"./math.js\";\n\nexport function kavrayskiy7Raw(lambda, phi) {\n return [3 / tau * lambda * sqrt(pi * pi / 3 - phi * phi), phi];\n}\n\nkavrayskiy7Raw.invert = function(x, y) {\n return [tau / 3 * x / sqrt(pi * pi / 3 - y * y), y];\n};\n\nexport default function() {\n return projection(kavrayskiy7Raw)\n .scale(158.837);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/kavrayskiy7.js","import {geoProjectionMutator as projectionMutator} from \"d3-geo\";\nimport {abs, asin, atan2, cos, epsilon, halfPi, pow, sign, sin} from \"./math.js\";\n\nexport function lagrangeRaw(n) {\n\n function forward(lambda, phi) {\n if (abs(abs(phi) - halfPi) < epsilon) return [0, phi < 0 ? -2 : 2];\n var sinPhi = sin(phi),\n v = pow((1 + sinPhi) / (1 - sinPhi), n / 2),\n c = 0.5 * (v + 1 / v) + cos(lambda *= n);\n return [\n 2 * sin(lambda) / c,\n (v - 1 / v) / c\n ];\n }\n\n forward.invert = function(x, y) {\n var y0 = abs(y);\n if (abs(y0 - 2) < epsilon) return x ? null : [0, sign(y) * halfPi];\n if (y0 > 2) return null;\n\n x /= 2, y /= 2;\n var x2 = x * x,\n y2 = y * y,\n t = 2 * y / (1 + x2 + y2); // tanh(nPhi)\n t = pow((1 + t) / (1 - t), 1 / n);\n return [\n atan2(2 * x, 1 - x2 - y2) / n,\n asin((t - 1) / (t + 1))\n ];\n };\n\n return forward;\n}\n\nexport default function() {\n var n = 0.5,\n m = projectionMutator(lagrangeRaw),\n p = m(n);\n\n p.spacing = function(_) {\n return arguments.length ? m(n = +_) : n;\n };\n\n return p\n .scale(124.75);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/lagrange.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, acos, cos, epsilon, halfPi, sin, pi, sqrt, sqrt2} from \"./math.js\";\n\nvar pi_sqrt2 = pi / sqrt2;\n\nexport function larriveeRaw(lambda, phi) {\n return [\n lambda * (1 + sqrt(cos(phi))) / 2,\n phi / (cos(phi / 2) * cos(lambda / 6))\n ];\n}\n\nlarriveeRaw.invert = function(x, y) {\n var x0 = abs(x),\n y0 = abs(y),\n lambda = epsilon,\n phi = halfPi;\n if (y0 < pi_sqrt2) phi *= y0 / pi_sqrt2;\n else lambda += 6 * acos(pi_sqrt2 / y0);\n for (var i = 0; i < 25; i++) {\n var sinPhi = sin(phi),\n sqrtcosPhi = sqrt(cos(phi)),\n sinPhi_2 = sin(phi / 2),\n cosPhi_2 = cos(phi / 2),\n sinLambda_6 = sin(lambda / 6),\n cosLambda_6 = cos(lambda / 6),\n f0 = 0.5 * lambda * (1 + sqrtcosPhi) - x0,\n f1 = phi / (cosPhi_2 * cosLambda_6) - y0,\n df0dPhi = sqrtcosPhi ? -0.25 * lambda * sinPhi / sqrtcosPhi : 0,\n df0dLambda = 0.5 * (1 + sqrtcosPhi),\n df1dPhi = (1 + 0.5 * phi * sinPhi_2 / cosPhi_2) / (cosPhi_2 * cosLambda_6),\n df1dLambda = (phi / cosPhi_2) * (sinLambda_6 / 6) / (cosLambda_6 * cosLambda_6),\n denom = df0dPhi * df1dLambda - df1dPhi * df0dLambda,\n dPhi = (f0 * df1dLambda - f1 * df0dLambda) / denom,\n dLambda = (f1 * df0dPhi - f0 * df1dPhi) / denom;\n phi -= dPhi;\n lambda -= dLambda;\n if (abs(dPhi) < epsilon && abs(dLambda) < epsilon) break;\n }\n return [x < 0 ? -lambda : lambda, y < 0 ? -phi : phi];\n};\n\nexport default function() {\n return projection(larriveeRaw)\n .scale(97.2672);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/larrivee.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, epsilon, pi, sign} from \"./math.js\";\n\nexport function laskowskiRaw(lambda, phi) {\n var lambda2 = lambda * lambda, phi2 = phi * phi;\n return [\n lambda * (0.975534 + phi2 * (-0.119161 + lambda2 * -0.0143059 + phi2 * -0.0547009)),\n phi * (1.00384 + lambda2 * (0.0802894 + phi2 * -0.02855 + lambda2 * 0.000199025) + phi2 * (0.0998909 + phi2 * -0.0491032))\n ];\n}\n\nlaskowskiRaw.invert = function(x, y) {\n var lambda = sign(x) * pi,\n phi = y / 2,\n i = 50;\n do {\n var lambda2 = lambda * lambda,\n phi2 = phi * phi,\n lambdaPhi = lambda * phi,\n fx = lambda * (0.975534 + phi2 * (-0.119161 + lambda2 * -0.0143059 + phi2 * -0.0547009)) - x,\n fy = phi * (1.00384 + lambda2 * (0.0802894 + phi2 * -0.02855 + lambda2 * 0.000199025) + phi2 * (0.0998909 + phi2 * -0.0491032)) - y,\n deltaxDeltaLambda = 0.975534 - phi2 * (0.119161 + 3 * lambda2 * 0.0143059 + phi2 * 0.0547009),\n deltaxDeltaPhi = -lambdaPhi * (2 * 0.119161 + 4 * 0.0547009 * phi2 + 2 * 0.0143059 * lambda2),\n deltayDeltaLambda = lambdaPhi * (2 * 0.0802894 + 4 * 0.000199025 * lambda2 + 2 * -0.02855 * phi2),\n deltayDeltaPhi = 1.00384 + lambda2 * (0.0802894 + 0.000199025 * lambda2) + phi2 * (3 * (0.0998909 - 0.02855 * lambda2) - 5 * 0.0491032 * phi2),\n denominator = deltaxDeltaPhi * deltayDeltaLambda - deltayDeltaPhi * deltaxDeltaLambda,\n deltaLambda = (fy * deltaxDeltaPhi - fx * deltayDeltaPhi) / denominator,\n deltaPhi = (fx * deltayDeltaLambda - fy * deltaxDeltaLambda) / denominator;\n lambda -= deltaLambda, phi -= deltaPhi;\n } while ((abs(deltaLambda) > epsilon || abs(deltaPhi) > epsilon) && --i > 0);\n return i && [lambda, phi];\n};\n\nexport default function() {\n return projection(laskowskiRaw)\n .scale(139.98);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/laskowski.js","import {geoProjection as projection} from \"d3-geo\";\nimport {acos, asin, cos, sign, sin, tan, sqrt, sqrt1_2} from \"./math.js\";\n\nexport function littrowRaw(lambda, phi) {\n return [\n sin(lambda) / cos(phi),\n tan(phi) * cos(lambda)\n ];\n}\n\nlittrowRaw.invert = function(x, y) {\n var x2 = x * x,\n y2 = y * y,\n y2_1 = y2 + 1,\n x2_y2_1 = x2 + y2_1,\n cosPhi = x\n ? sqrt1_2 * sqrt((x2_y2_1 - sqrt(x2_y2_1 * x2_y2_1 - 4 * x2)) / x2)\n : 1 / sqrt(y2_1);\n return [\n asin(x * cosPhi),\n sign(y) * acos(cosPhi)\n ];\n};\n\nexport default function() {\n return projection(littrowRaw)\n .scale(144.049)\n .clipAngle(90 - 1e-3);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/littrow.js","import {geoProjection as projection} from \"d3-geo\";\nimport {atan, exp, log, quarterPi, pi, tan} from \"./math.js\";\n\nexport function millerRaw(lambda, phi) {\n return [lambda, 1.25 * log(tan(quarterPi + 0.4 * phi))];\n}\n\nmillerRaw.invert = function(x, y) {\n return [x, 2.5 * atan(exp(0.8 * y)) - 0.625 * pi];\n};\n\nexport default function() {\n return projection(millerRaw)\n .scale(108.318);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/miller.js","import {geoProjection as projection} from \"d3-geo\";\nimport {asin, cos, sin, sqrt} from \"./math.js\";\n\nvar sqrt6 = sqrt(6),\n sqrt7 = sqrt(7);\n\nexport function mtFlatPolarParabolicRaw(lambda, phi) {\n var theta = asin(7 * sin(phi) / (3 * sqrt6));\n return [\n sqrt6 * lambda * (2 * cos(2 * theta / 3) - 1) / sqrt7,\n 9 * sin(theta / 3) / sqrt7\n ];\n}\n\nmtFlatPolarParabolicRaw.invert = function(x, y) {\n var theta = 3 * asin(y * sqrt7 / 9);\n return [\n x * sqrt7 / (sqrt6 * (2 * cos(2 * theta / 3) - 1)),\n asin(sin(theta) * 3 * sqrt6 / 7)\n ];\n};\n\nexport default function() {\n return projection(mtFlatPolarParabolicRaw)\n .scale(164.859);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mtFlatPolarParabolic.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, cos, epsilon, sin, sqrt, sqrt1_2, sqrt2} from \"./math.js\";\n\nexport function mtFlatPolarQuarticRaw(lambda, phi) {\n var k = (1 + sqrt1_2) * sin(phi),\n theta = phi;\n for (var i = 0, delta; i < 25; i++) {\n theta -= delta = (sin(theta / 2) + sin(theta) - k) / (0.5 * cos(theta / 2) + cos(theta));\n if (abs(delta) < epsilon) break;\n }\n return [\n lambda * (1 + 2 * cos(theta) / cos(theta / 2)) / (3 * sqrt2),\n 2 * sqrt(3) * sin(theta / 2) / sqrt(2 + sqrt2)\n ];\n}\n\nmtFlatPolarQuarticRaw.invert = function(x, y) {\n var sinTheta_2 = y * sqrt(2 + sqrt2) / (2 * sqrt(3)),\n theta = 2 * asin(sinTheta_2);\n return [\n 3 * sqrt2 * x / (1 + 2 * cos(theta) / cos(theta / 2)),\n asin((sinTheta_2 + sin(theta)) / (1 + sqrt1_2))\n ];\n};\n\nexport default function() {\n return projection(mtFlatPolarQuarticRaw)\n .scale(188.209);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mtFlatPolarQuartic.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, cos, epsilon, halfPi, pi, sin, sqrt} from \"./math.js\";\n\nexport function mtFlatPolarSinusoidalRaw(lambda, phi) {\n var A = sqrt(6 / (4 + pi)),\n k = (1 + pi / 4) * sin(phi),\n theta = phi / 2;\n for (var i = 0, delta; i < 25; i++) {\n theta -= delta = (theta / 2 + sin(theta) - k) / (0.5 + cos(theta));\n if (abs(delta) < epsilon) break;\n }\n return [\n A * (0.5 + cos(theta)) * lambda / 1.5,\n A * theta\n ];\n}\n\nmtFlatPolarSinusoidalRaw.invert = function(x, y) {\n var A = sqrt(6 / (4 + pi)),\n theta = y / A;\n if (abs(abs(theta) - halfPi) < epsilon) theta = theta < 0 ? -halfPi : halfPi;\n return [\n 1.5 * x / (A * (0.5 + cos(theta))),\n asin((theta / 2 + sin(theta)) / (1 + pi / 4))\n ];\n};\n\nexport default function() {\n return projection(mtFlatPolarSinusoidalRaw)\n .scale(166.518);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/mtFlatPolarSinusoidal.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, epsilon2} from \"./math.js\";\n\nexport function naturalEarth2Raw(lambda, phi) {\n var phi2 = phi * phi, phi4 = phi2 * phi2, phi6 = phi2 * phi4;\n return [\n lambda * (0.84719 - 0.13063 * phi2 + phi6 * phi6 * (-0.04515 + 0.05494 * phi2 - 0.02326 * phi4 + 0.00331 * phi6)),\n phi * (1.01183 + phi4 * phi4 * (-0.02625 + 0.01926 * phi2 - 0.00396 * phi4))\n ];\n}\n\nnaturalEarth2Raw.invert = function(x, y) {\n var phi = y, i = 25, delta, phi2, phi4, phi6;\n do {\n phi2 = phi * phi; phi4 = phi2 * phi2;\n phi -= delta = ((phi * (1.01183 + phi4 * phi4 * (-0.02625 + 0.01926 * phi2 - 0.00396 * phi4))) - y) /\n (1.01183 + phi4 * phi4 * ((9 * -0.02625) + (11 * 0.01926) * phi2 + (13 * -0.00396) * phi4));\n } while (abs(delta) > epsilon2 && --i > 0);\n phi2 = phi * phi; phi4 = phi2 * phi2; phi6 = phi2 * phi4;\n return [\n x / (0.84719 - 0.13063 * phi2 + phi6 * phi6 * (-0.04515 + 0.05494 * phi2 - 0.02326 * phi4 + 0.00331 * phi6)),\n phi\n ];\n};\n\nexport default function() {\n return projection(naturalEarth2Raw)\n .scale(175.295);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/naturalEarth2.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, cos, epsilon, tan} from \"./math.js\";\n\nexport function nellHammerRaw(lambda, phi) {\n return [\n lambda * (1 + cos(phi)) / 2,\n 2 * (phi - tan(phi / 2))\n ];\n}\n\nnellHammerRaw.invert = function(x, y) {\n var p = y / 2;\n for (var i = 0, delta = Infinity; i < 10 && abs(delta) > epsilon; ++i) {\n var c = cos(y / 2);\n y -= delta = (y - tan(y / 2) - p) / (1 - 0.5 / (c * c));\n }\n return [\n 2 * x / (1 + cos(y)),\n y\n ];\n};\n\nexport default function() {\n return projection(nellHammerRaw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/nellHammer.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, cos, halfPi, pi, sign, sin, sqrt} from \"./math.js\";\nimport {solve} from \"./newton.js\";\n\n// Based on Torben Jansen's implementation\n// https://beta.observablehq.com/@toja/nicolosi-globular-projection\n// https://beta.observablehq.com/@toja/nicolosi-globular-inverse\n\nexport function nicolosiRaw(lambda, phi) {\n var sinPhi = sin(phi),\n q = cos(phi),\n s = sign(lambda);\n\n if (lambda === 0 || abs(phi) === halfPi) return [0, phi];\n else if (phi === 0) return [lambda, 0];\n else if (abs(lambda) === halfPi) return [lambda * q, halfPi * sinPhi];\n\n var b = pi / (2 * lambda) - (2 * lambda) / pi,\n c = (2 * phi) / pi,\n d = (1 - c * c) / (sinPhi - c);\n\n var b2 = b * b,\n d2 = d * d,\n b2d2 = 1 + b2 / d2,\n d2b2 = 1 + d2 / b2;\n\n var M = ((b * sinPhi) / d - b / 2) / b2d2,\n N = ((d2 * sinPhi) / b2 + d / 2) / d2b2,\n m = M * M + (q * q) / b2d2,\n n = N * N - ((d2 * sinPhi * sinPhi) / b2 + d * sinPhi - 1) / d2b2;\n\n return [\n halfPi * (M + sqrt(m) * s),\n halfPi * (N + sqrt(n < 0 ? 0 : n) * sign(-phi * b) * s)\n ];\n}\n\nnicolosiRaw.invert = function(x, y) {\n\n x /= halfPi;\n y /= halfPi;\n\n var x2 = x * x,\n y2 = y * y,\n x2y2 = x2 + y2,\n pi2 = pi * pi;\n\n return [\n x ? (x2y2 -1 + sqrt((1 - x2y2) * (1 - x2y2) + 4 * x2)) / (2 * x) * halfPi : 0,\n solve(function(phi) {\n return (\n x2y2 * (pi * sin(phi) - 2 * phi) * pi +\n 4 * phi * phi * (y - sin(phi)) +\n 2 * pi * phi -\n pi2 * y\n );\n }, 0)\n ];\n};\n\nexport default function() {\n return projection(nicolosiRaw)\n .scale(127.267);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/nicolosi.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, epsilon} from \"./math.js\";\n\n// Based on Java implementation by Bojan Savric.\n// https://github.com/OSUCartography/JMapProjLib/blob/master/src/com/jhlabs/map/proj/PattersonProjection.java\n\nvar pattersonK1 = 1.0148,\n pattersonK2 = 0.23185,\n pattersonK3 = -0.14499,\n pattersonK4 = 0.02406,\n pattersonC1 = pattersonK1,\n pattersonC2 = 5 * pattersonK2,\n pattersonC3 = 7 * pattersonK3,\n pattersonC4 = 9 * pattersonK4,\n pattersonYmax = 1.790857183;\n\nexport function pattersonRaw(lambda, phi) {\n var phi2 = phi * phi;\n return [\n lambda,\n phi * (pattersonK1 + phi2 * phi2 * (pattersonK2 + phi2 * (pattersonK3 + pattersonK4 * phi2)))\n ];\n}\n\npattersonRaw.invert = function(x, y) {\n if (y > pattersonYmax) y = pattersonYmax;\n else if (y < -pattersonYmax) y = -pattersonYmax;\n var yc = y, delta;\n\n do { // Newton-Raphson\n var y2 = yc * yc;\n yc -= delta = ((yc * (pattersonK1 + y2 * y2 * (pattersonK2 + y2 * (pattersonK3 + pattersonK4 * y2)))) - y) / (pattersonC1 + y2 * y2 * (pattersonC2 + y2 * (pattersonC3 + pattersonC4 * y2)));\n } while (abs(delta) > epsilon);\n\n return [x, yc];\n};\n\nexport default function() {\n return projection(pattersonRaw)\n .scale(139.319);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/patterson.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, acos, asin, cos, epsilon, halfPi, sign, sin, tan} from \"./math.js\";\n\nexport function polyconicRaw(lambda, phi) {\n if (abs(phi) < epsilon) return [lambda, 0];\n var tanPhi = tan(phi),\n k = lambda * sin(phi);\n return [\n sin(k) / tanPhi,\n phi + (1 - cos(k)) / tanPhi\n ];\n}\n\npolyconicRaw.invert = function(x, y) {\n if (abs(y) < epsilon) return [x, 0];\n var k = x * x + y * y,\n phi = y * 0.5,\n i = 10, delta;\n do {\n var tanPhi = tan(phi),\n secPhi = 1 / cos(phi),\n j = k - 2 * y * phi + phi * phi;\n phi -= delta = (tanPhi * j + 2 * (phi - y)) / (2 + j * secPhi * secPhi + 2 * (phi - y) * tanPhi);\n } while (abs(delta) > epsilon && --i > 0);\n tanPhi = tan(phi);\n return [\n (abs(y) < abs(phi + 1 / tanPhi) ? asin(x * tanPhi) : sign(y) * sign(x) * (acos(abs(x * tanPhi)) + halfPi)) / sin(phi),\n phi\n ];\n};\n\nexport default function() {\n return projection(polyconicRaw)\n .scale(103.74);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/polyconic.js","// TODO generate on-the-fly to avoid external modification.\nvar octahedron = [\n [0, 90],\n [-90, 0], [0, 0], [90, 0], [180, 0],\n [0, -90]\n];\n\nexport default [\n [0, 2, 1],\n [0, 3, 2],\n [5, 1, 2],\n [5, 2, 3],\n [0, 1, 4],\n [0, 4, 3],\n [5, 4, 1],\n [5, 3, 4]\n].map(function(face) {\n return face.map(function(i) {\n return octahedron[i];\n });\n});\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/polyhedral/octahedron.js","import {geoCentroid as centroid, geoProjection as projection} from \"d3-geo\";\nimport {collignonRaw} from \"../collignon.js\";\nimport {pi, sqrt} from \"../math.js\";\nimport polyhedral from \"./index.js\";\nimport octahedron from \"./octahedron.js\";\n\nvar kx = 2 / sqrt(3);\n\nfunction collignonK(a, b) {\n var p = collignonRaw(a, b);\n return [p[0] * kx, p[1]];\n}\n\ncollignonK.invert = function(x,y) {\n return collignonRaw.invert(x / kx, y);\n};\n\nexport default function(faceProjection) {\n\n faceProjection = faceProjection || function(face) {\n var c = centroid({type: \"MultiPoint\", coordinates: face});\n return projection(collignonK).translate([0, 0]).scale(1).rotate(c[1] > 0 ? [-c[0], 0] : [180 - c[0], 180]);\n };\n\n var faces = octahedron.map(function(face) {\n return {face: face, project: faceProjection(face)};\n });\n\n [-1, 0, 0, 1, 0, 1, 4, 5].forEach(function(d, i) {\n var node = faces[d];\n node && (node.children || (node.children = [])).push(faces[i]);\n });\n\n return polyhedral(faces[0], function(lambda, phi) {\n return faces[lambda < -pi / 2 ? phi < 0 ? 6 : 4\n : lambda < 0 ? phi < 0 ? 2 : 0\n : lambda < pi / 2 ? phi < 0 ? 3 : 1\n : phi < 0 ? 7 : 5];\n })\n .angle(-30)\n .scale(121.906)\n .center([0, 48.5904]);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/polyhedral/collignon.js","import {abs, acos, asin, atan, cos, epsilon, pi, sin, tan} from \"./math.js\";\nimport parallel1 from \"./parallel1.js\";\n\nexport function rectangularPolyconicRaw(phi0) {\n var sinPhi0 = sin(phi0);\n\n function forward(lambda, phi) {\n var A = sinPhi0 ? tan(lambda * sinPhi0 / 2) / sinPhi0 : lambda / 2;\n if (!phi) return [2 * A, -phi0];\n var E = 2 * atan(A * sin(phi)),\n cotPhi = 1 / tan(phi);\n return [\n sin(E) * cotPhi,\n phi + (1 - cos(E)) * cotPhi - phi0\n ];\n }\n\n // TODO return null for points outside outline.\n forward.invert = function(x, y) {\n if (abs(y += phi0) < epsilon) return [sinPhi0 ? 2 * atan(sinPhi0 * x / 2) / sinPhi0 : x, 0];\n var k = x * x + y * y,\n phi = 0,\n i = 10, delta;\n do {\n var tanPhi = tan(phi),\n secPhi = 1 / cos(phi),\n j = k - 2 * y * phi + phi * phi;\n phi -= delta = (tanPhi * j + 2 * (phi - y)) / (2 + j * secPhi * secPhi + 2 * (phi - y) * tanPhi);\n } while (abs(delta) > epsilon && --i > 0);\n var E = x * (tanPhi = tan(phi)),\n A = tan(abs(y) < abs(phi + 1 / tanPhi) ? asin(E) * 0.5 : acos(E) * 0.5 + pi / 4) / sin(phi);\n return [\n sinPhi0 ? 2 * atan(sinPhi0 * A) / sinPhi0 : 2 * A,\n phi\n ];\n };\n\n return forward;\n}\n\nexport default function() {\n return parallel1(rectangularPolyconicRaw)\n .scale(131.215);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/rectangularPolyconic.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, degrees, epsilon2, floor, halfPi, max, min, pi, radians} from \"./math.js\";\n\nvar K = [\n [0.9986, -0.062],\n [1.0000, 0.0000],\n [0.9986, 0.0620],\n [0.9954, 0.1240],\n [0.9900, 0.1860],\n [0.9822, 0.2480],\n [0.9730, 0.3100],\n [0.9600, 0.3720],\n [0.9427, 0.4340],\n [0.9216, 0.4958],\n [0.8962, 0.5571],\n [0.8679, 0.6176],\n [0.8350, 0.6769],\n [0.7986, 0.7346],\n [0.7597, 0.7903],\n [0.7186, 0.8435],\n [0.6732, 0.8936],\n [0.6213, 0.9394],\n [0.5722, 0.9761],\n [0.5322, 1.0000]\n];\n\nK.forEach(function(d) {\n d[1] *= 1.0144;\n});\n\nexport function robinsonRaw(lambda, phi) {\n var i = min(18, abs(phi) * 36 / pi),\n i0 = floor(i),\n di = i - i0,\n ax = (k = K[i0])[0],\n ay = k[1],\n bx = (k = K[++i0])[0],\n by = k[1],\n cx = (k = K[min(19, ++i0)])[0],\n cy = k[1],\n k;\n return [\n lambda * (bx + di * (cx - ax) / 2 + di * di * (cx - 2 * bx + ax) / 2),\n (phi > 0 ? halfPi : -halfPi) * (by + di * (cy - ay) / 2 + di * di * (cy - 2 * by + ay) / 2)\n ];\n}\n\nrobinsonRaw.invert = function(x, y) {\n var yy = y / halfPi,\n phi = yy * 90,\n i = min(18, abs(phi / 5)),\n i0 = max(0, floor(i));\n do {\n var ay = K[i0][1],\n by = K[i0 + 1][1],\n cy = K[min(19, i0 + 2)][1],\n u = cy - ay,\n v = cy - 2 * by + ay,\n t = 2 * (abs(yy) - by) / u,\n c = v / u,\n di = t * (1 - c * t * (1 - 2 * c * t));\n if (di >= 0 || i0 === 1) {\n phi = (y >= 0 ? 5 : -5) * (di + i);\n var j = 50, delta;\n do {\n i = min(18, abs(phi) / 5);\n i0 = floor(i);\n di = i - i0;\n ay = K[i0][1];\n by = K[i0 + 1][1];\n cy = K[min(19, i0 + 2)][1];\n phi -= (delta = (y >= 0 ? halfPi : -halfPi) * (by + di * (cy - ay) / 2 + di * di * (cy - 2 * by + ay) / 2) - y) * degrees;\n } while (abs(delta) > epsilon2 && --j > 0);\n break;\n }\n } while (--i0 >= 0);\n var ax = K[i0][0],\n bx = K[i0 + 1][0],\n cx = K[min(19, i0 + 2)][0];\n return [\n x / (bx + di * (cx - ax) / 2 + di * di * (cx - 2 * bx + ax) / 2),\n phi * radians\n ];\n};\n\nexport default function() {\n return projection(robinsonRaw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/robinson.js","import {geoProjection as projection} from \"d3-geo\";\nimport {atan, quarterPi, sin, tan} from \"./math.js\";\n\nexport function timesRaw(lambda, phi) {\n var t = tan(phi / 2),\n s = sin(quarterPi * t);\n return [\n lambda * (0.74482 - 0.34588 * s * s),\n 1.70711 * t\n ];\n}\n\ntimesRaw.invert = function(x, y) {\n var t = y / 1.70711,\n s = sin(quarterPi * t);\n return [\n x / (0.74482 - 0.34588 * s * s),\n 2 * atan(t)\n ];\n};\n\nexport default function() {\n return projection(timesRaw)\n .scale(146.153);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/times.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, acos, asin, atan, cos, epsilon, halfPi, pi, sign, sin, sqrt, tan} from \"./math.js\";\n\nexport function vanDerGrintenRaw(lambda, phi) {\n if (abs(phi) < epsilon) return [lambda, 0];\n var sinTheta = abs(phi / halfPi),\n theta = asin(sinTheta);\n if (abs(lambda) < epsilon || abs(abs(phi) - halfPi) < epsilon) return [0, sign(phi) * pi * tan(theta / 2)];\n var cosTheta = cos(theta),\n A = abs(pi / lambda - lambda / pi) / 2,\n A2 = A * A,\n G = cosTheta / (sinTheta + cosTheta - 1),\n P = G * (2 / sinTheta - 1),\n P2 = P * P,\n P2_A2 = P2 + A2,\n G_P2 = G - P2,\n Q = A2 + G;\n return [\n sign(lambda) * pi * (A * G_P2 + sqrt(A2 * G_P2 * G_P2 - P2_A2 * (G * G - P2))) / P2_A2,\n sign(phi) * pi * (P * Q - A * sqrt((A2 + 1) * P2_A2 - Q * Q)) / P2_A2\n ];\n}\n\nvanDerGrintenRaw.invert = function(x, y) {\n if (abs(y) < epsilon) return [x, 0];\n if (abs(x) < epsilon) return [0, halfPi * sin(2 * atan(y / pi))];\n var x2 = (x /= pi) * x,\n y2 = (y /= pi) * y,\n x2_y2 = x2 + y2,\n z = x2_y2 * x2_y2,\n c1 = -abs(y) * (1 + x2_y2),\n c2 = c1 - 2 * y2 + x2,\n c3 = -2 * c1 + 1 + 2 * y2 + z,\n d = y2 / c3 + (2 * c2 * c2 * c2 / (c3 * c3 * c3) - 9 * c1 * c2 / (c3 * c3)) / 27,\n a1 = (c1 - c2 * c2 / (3 * c3)) / c3,\n m1 = 2 * sqrt(-a1 / 3),\n theta1 = acos(3 * d / (a1 * m1)) / 3;\n return [\n pi * (x2_y2 - 1 + sqrt(1 + 2 * (x2 - y2) + z)) / (2 * x),\n sign(y) * pi * (-m1 * cos(theta1 + pi / 3) - c2 / (3 * c3))\n ];\n};\n\nexport default function() {\n return projection(vanDerGrintenRaw)\n .scale(79.4183);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, atan, atan2, cos, halfPi, epsilon, pi, sign, sin, sqrt, tan} from \"./math.js\";\n\nexport function vanDerGrinten2Raw(lambda, phi) {\n if (abs(phi) < epsilon) return [lambda, 0];\n var sinTheta = abs(phi / halfPi),\n theta = asin(sinTheta);\n if (abs(lambda) < epsilon || abs(abs(phi) - halfPi) < epsilon) return [0, sign(phi) * pi * tan(theta / 2)];\n var cosTheta = cos(theta),\n A = abs(pi / lambda - lambda / pi) / 2,\n A2 = A * A,\n x1 = cosTheta * (sqrt(1 + A2) - A * cosTheta) / (1 + A2 * sinTheta * sinTheta);\n return [\n sign(lambda) * pi * x1,\n sign(phi) * pi * sqrt(1 - x1 * (2 * A + x1))\n ];\n}\n\nvanDerGrinten2Raw.invert = function(x, y) {\n if (!x) return [0, halfPi * sin(2 * atan(y / pi))];\n var x1 = abs(x / pi),\n A = (1 - x1 * x1 - (y /= pi) * y) / (2 * x1),\n A2 = A * A,\n B = sqrt(A2 + 1);\n return [\n sign(x) * pi * (B - A),\n sign(y) * halfPi * sin(2 * atan2(sqrt((1 - 2 * A * x1) * (A + B) - x1), sqrt(B + A + x1)))\n ];\n};\n\nexport default function() {\n return projection(vanDerGrinten2Raw)\n .scale(79.4183);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten2.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, asin, atan, cos, epsilon, halfPi, pi, sign, sin, sqrt, tan} from \"./math.js\";\n\nexport function vanDerGrinten3Raw(lambda, phi) {\n if (abs(phi) < epsilon) return [lambda, 0];\n var sinTheta = phi / halfPi,\n theta = asin(sinTheta);\n if (abs(lambda) < epsilon || abs(abs(phi) - halfPi) < epsilon) return [0, pi * tan(theta / 2)];\n var A = (pi / lambda - lambda / pi) / 2,\n y1 = sinTheta / (1 + cos(theta));\n return [\n pi * (sign(lambda) * sqrt(A * A + 1 - y1 * y1) - A),\n pi * y1\n ];\n}\n\nvanDerGrinten3Raw.invert = function(x, y) {\n if (!y) return [x, 0];\n var y1 = y / pi,\n A = (pi * pi * (1 - y1 * y1) - x * x) / (2 * pi * x);\n return [\n x ? pi * (sign(x) * sqrt(A * A + 1) - A) : 0,\n halfPi * sin(2 * atan(y1))\n ];\n};\n\nexport default function() {\n return projection(vanDerGrinten3Raw)\n .scale(79.4183);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten3.js","import {geoProjection as projection} from \"d3-geo\";\nimport {abs, epsilon, halfPi, min, pi, sign, sqrt} from \"./math.js\";\n\nexport function vanDerGrinten4Raw(lambda, phi) {\n if (!phi) return [lambda, 0];\n var phi0 = abs(phi);\n if (!lambda || phi0 === halfPi) return [0, phi];\n var B = phi0 / halfPi,\n B2 = B * B,\n C = (8 * B - B2 * (B2 + 2) - 5) / (2 * B2 * (B - 1)),\n C2 = C * C,\n BC = B * C,\n B_C2 = B2 + C2 + 2 * BC,\n B_3C = B + 3 * C,\n lambda0 = lambda / halfPi,\n lambda1 = lambda0 + 1 / lambda0,\n D = sign(abs(lambda) - halfPi) * sqrt(lambda1 * lambda1 - 4),\n D2 = D * D,\n F = B_C2 * (B2 + C2 * D2 - 1) + (1 - B2) * (B2 * (B_3C * B_3C + 4 * C2) + 12 * BC * C2 + 4 * C2 * C2),\n x1 = (D * (B_C2 + C2 - 1) + 2 * sqrt(F)) / (4 * B_C2 + D2);\n return [\n sign(lambda) * halfPi * x1,\n sign(phi) * halfPi * sqrt(1 + D * abs(x1) - x1 * x1)\n ];\n}\n\nvanDerGrinten4Raw.invert = function(x, y) {\n var delta;\n if (!x || !y) return [x, y];\n var sy = sign(y);\n y = abs(y) / pi;\n var x1 = sign(x) * x / halfPi,\n D = (x1 * x1 - 1 + 4 * y * y) / abs(x1),\n D2 = D * D,\n B = y * (2 - (y > 0.5 ? min(y, abs(x)) : 0)),\n r = x * x + y * y,\n i = 50;\n do {\n var B2 = B * B,\n C = (8 * B - B2 * (B2 + 2) - 5) / (2 * B2 * (B - 1)),\n C_ = (3 * B - B2 * B - 10) / (2 * B2 * B),\n C2 = C * C,\n BC = B * C,\n B_C = B + C,\n B_C2 = B_C * B_C,\n B_3C = B + 3 * C,\n F = B_C2 * (B2 + C2 * D2 - 1) + (1 - B2) * (B2 * (B_3C * B_3C + 4 * C2) + C2 * (12 * BC + 4 * C2)),\n F_ = -2 * B_C * (4 * BC * C2 + (1 - 4 * B2 + 3 * B2 * B2) * (1 + C_) + C2 * (-6 + 14 * B2 - D2 + (-8 + 8 * B2 - 2 * D2) * C_) + BC * (-8 + 12 * B2 + (-10 + 10 * B2 - D2) * C_)),\n sqrtF = sqrt(F),\n f = D * (B_C2 + C2 - 1) + 2 * sqrtF - x1 * (4 * B_C2 + D2),\n f_ = D * (2 * C * C_ + 2 * B_C * (1 + C_)) + F_ / sqrtF - 8 * B_C * (D * (-1 + C2 + B_C2) + 2 * sqrtF) * (1 + C_) / (D2 + 4 * B_C2);\n B -= delta = f / f_;\n } while (delta * r * r > epsilon && --i > 0);\n return [\n sign(x) * (sqrt(D * D + 4) + D) * pi / 4,\n sy * halfPi * B\n ];\n};\n\nexport default function() {\n return projection(vanDerGrinten4Raw)\n .scale(127.16);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/vanDerGrinten4.js","import {geoProjection as projection} from \"d3-geo\";\nimport {sqrt, pi} from \"./math.js\";\nimport {mollweideBromleyRaw} from \"./mollweide.js\";\n\nvar A = 4 * pi + 3 * sqrt(3),\n B = 2 * sqrt(2 * pi * sqrt(3) / A);\n\nexport var wagner4Raw = mollweideBromleyRaw(B * sqrt(3) / pi, B, A / 6);\n\nexport default function() {\n return projection(wagner4Raw)\n .scale(176.84);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/wagner4.js","import {geoProjection as projection} from \"d3-geo\";\nimport {pi, sqrt} from \"./math.js\";\n\nexport function wagner6Raw(lambda, phi) {\n return [lambda * sqrt(1 - 3 * phi * phi / (pi * pi)), phi];\n}\n\nwagner6Raw.invert = function(x, y) {\n return [x / sqrt(1 - 3 * y * y / (pi * pi)), y];\n};\n\nexport default function() {\n return projection(wagner6Raw)\n .scale(152.63);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/wagner6.js","import {geoProjection as projection} from \"d3-geo\";\nimport {asin, atan2, cos, sin, sqrt} from \"./math.js\";\n\nexport function wiechelRaw(lambda, phi) {\n var cosPhi = cos(phi),\n sinPhi = cos(lambda) * cosPhi,\n sin1_Phi = 1 - sinPhi,\n cosLambda = cos(lambda = atan2(sin(lambda) * cosPhi, -sin(phi))),\n sinLambda = sin(lambda);\n cosPhi = sqrt(1 - sinPhi * sinPhi);\n return [\n sinLambda * cosPhi - cosLambda * sin1_Phi,\n -cosLambda * cosPhi - sinLambda * sin1_Phi\n ];\n}\n\nwiechelRaw.invert = function(x, y) {\n var w = (x * x + y * y) / -2,\n k = sqrt(-w * (2 + w)),\n b = y * w + x * k,\n a = x * w - y * k,\n D = sqrt(a * a + b * b);\n return [\n atan2(k * b, D * (1 + w)),\n D ? -asin(k * a / D) : 0\n ];\n};\n\nexport default function() {\n return projection(wiechelRaw)\n .rotate([0, -90, 45])\n .scale(124.75)\n .clipAngle(180 - 1e-3);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/wiechel.js","import {geoProjection as projection} from \"d3-geo\";\nimport {aitoffRaw} from \"./aitoff.js\";\nimport {halfPi, epsilon, sin, cos, sqrt, abs, acos} from \"./math.js\";\n\nexport function winkel3Raw(lambda, phi) {\n var coordinates = aitoffRaw(lambda, phi);\n return [\n (coordinates[0] + lambda / halfPi) / 2,\n (coordinates[1] + phi) / 2\n ];\n}\n\nwinkel3Raw.invert = function(x, y) {\n var lambda = x, phi = y, i = 25;\n do {\n var cosphi = cos(phi),\n sinphi = sin(phi),\n sin_2phi = sin(2 * phi),\n sin2phi = sinphi * sinphi,\n cos2phi = cosphi * cosphi,\n sinlambda = sin(lambda),\n coslambda_2 = cos(lambda / 2),\n sinlambda_2 = sin(lambda / 2),\n sin2lambda_2 = sinlambda_2 * sinlambda_2,\n C = 1 - cos2phi * coslambda_2 * coslambda_2,\n E = C ? acos(cosphi * coslambda_2) * sqrt(F = 1 / C) : F = 0,\n F,\n fx = 0.5 * (2 * E * cosphi * sinlambda_2 + lambda / halfPi) - x,\n fy = 0.5 * (E * sinphi + phi) - y,\n dxdlambda = 0.5 * F * (cos2phi * sin2lambda_2 + E * cosphi * coslambda_2 * sin2phi) + 0.5 / halfPi,\n dxdphi = F * (sinlambda * sin_2phi / 4 - E * sinphi * sinlambda_2),\n dydlambda = 0.125 * F * (sin_2phi * sinlambda_2 - E * sinphi * cos2phi * sinlambda),\n dydphi = 0.5 * F * (sin2phi * coslambda_2 + E * sin2lambda_2 * cosphi) + 0.5,\n denominator = dxdphi * dydlambda - dydphi * dxdlambda,\n dlambda = (fy * dxdphi - fx * dydphi) / denominator,\n dphi = (fx * dydlambda - fy * dxdlambda) / denominator;\n lambda -= dlambda, phi -= dphi;\n } while ((abs(dlambda) > epsilon || abs(dphi) > epsilon) && --i > 0);\n return [lambda, phi];\n};\n\nexport default function() {\n return projection(winkel3Raw)\n .scale(158.837);\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/d3-geo-projection/src/winkel3.js","/**\n * Functionality for Miller projection\n *\n * The function(s) below are from D3.js library (https://d3js.org/)\n *\n * ```\n * Copyright 2017 Mike Bostock\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions are met:\n *\n * 1. Redistributions of source code must retain the above copyright notice,\n * this list of conditions and the following disclaimer.\n *\n * 2. Redistributions in binary form must reproduce the above copyright notice,\n * this list of conditions and the following disclaimer in the documentation\n * and/or other materials provided with the distribution.\n *\n * 3. Neither the name of the copyright holder nor the names of its\n * contributors may be used to endorse or promote products derived from this\n * software without specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\n * POSSIBILITY OF SUCH DAMAGE.\n * ```\n */\n\n/**\n * ============================================================================\n * IMPORTS\n * ============================================================================\n * @hidden\n */\nimport { Projection } from \"./Projection\";\nimport { registry } from \"../../../core/Registry\";\n// @ts-ignore\nimport * as d3geoprojection from \"d3-geo-projection\";\n\n\n/**\n * Miller projection.\n */\nexport class Miller extends Projection {\n\tconstructor(){\n\t\tsuper();\n\t\tthis.d3Projection = d3geoprojection.geoMiller();\n\t}\n}\n\n/**\n * Register class in system, so that it can be instantiated using its name from\n * anywhere.\n *\n * @ignore\n */\nregistry.registeredClasses[\"Miller\"] = Miller;\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/Miller.ts","/**\r\n * Functionality for Eckert6 projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\n// @ts-ignore\r\nimport * as d3geoprojection from \"d3-geo-projection\";\r\n\r\n/**\r\n * Eckert6 projection.\r\n */\r\nexport class Eckert6 extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geoprojection.geoEckert6();\r\n\t}\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"Eckert6\"] = Eckert6;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/Eckert6.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Orthographic projection.\r\n */\r\nexport class Orthographic extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoOrthographic();\r\n\t}\t\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"Orthographic\"] = Orthographic;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/Orthographic.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Orthographic projection.\r\n */\r\nexport class Stereographic extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoStereographic();\r\n\t}\t\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"Stereographic\"] = Stereographic;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/Stereographic.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Orthographic projection.\r\n */\r\nexport class Albers extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoAlbers();\r\n\t}\t\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"Albers\"] = Albers;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/Albers.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Orthographic projection.\r\n */\r\nexport class AlbersUsa extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoAlbersUsa();\r\n\t}\t\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"AlbersUsa\"] = AlbersUsa;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/AlbersUsa.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Orthographic projection.\r\n */\r\nexport class NaturalEarth1 extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoNaturalEarth1();\r\n\t}\t\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"NaturalEarth1\"] = NaturalEarth1;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/NaturalEarth1.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Orthographic projection.\r\n */\r\nexport class AzimuthalEqualArea extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoAzimuthalEqualArea();\r\n\t}\t\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"AzimuthalEqualArea\"] = AzimuthalEqualArea;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/AzimuthalEqualArea.ts","/**\r\n * Functionality for Mercator projection\r\n *\r\n * The function(s) below are from D3.js library (https://d3js.org/)\r\n *\r\n * ```\r\n * Copyright 2017 Mike Bostock\r\n *\r\n * Redistribution and use in source and binary forms, with or without\r\n * modification, are permitted provided that the following conditions are met:\r\n *\r\n * 1. Redistributions of source code must retain the above copyright notice,\r\n * this list of conditions and the following disclaimer.\r\n *\r\n * 2. Redistributions in binary form must reproduce the above copyright notice,\r\n * this list of conditions and the following disclaimer in the documentation\r\n * and/or other materials provided with the distribution.\r\n *\r\n * 3. Neither the name of the copyright holder nor the names of its\r\n * contributors may be used to endorse or promote products derived from this\r\n * software without specific prior written permission.\r\n *\r\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r\n * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r\n * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\n * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE\r\n * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR\r\n * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF\r\n * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\n * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\n * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\n * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\r\n * POSSIBILITY OF SUCH DAMAGE.\r\n * ```\r\n */\r\n\r\n/**\r\n * ============================================================================\r\n * IMPORTS\r\n * ============================================================================\r\n * @hidden\r\n */\r\nimport { Projection } from \"./Projection\";\r\nimport { registry } from \"../../../core/Registry\";\r\nimport * as d3geo from \"d3-geo\";\r\n\r\n\r\n/**\r\n * Orthographic projection.\r\n */\r\nexport class EqualEarth extends Projection {\r\n\tconstructor(){\r\n\t\tsuper();\r\n\t\tthis.d3Projection = d3geo.geoEqualEarth();\r\n\t}\t\r\n}\r\n\r\n/**\r\n * Register class in system, so that it can be instantiated using its name from\r\n * anywhere.\r\n *\r\n * @ignore\r\n */\r\nregistry.registeredClasses[\"EqualEarth\"] = EqualEarth;\r\n\n\n\n// WEBPACK FOOTER //\n// ../../../../../../src/.internal/charts/map/projections/EqualEarth.ts","import * as m from \"../es2015/maps\";\nwindow.am4maps = m;\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./maps.js\n// module id = null\n// module chunks = ","\nexport default class TinyQueue {\n constructor(data = [], compare = defaultCompare) {\n this.data = data;\n this.length = this.data.length;\n this.compare = compare;\n\n if (this.length > 0) {\n for (let i = (this.length >> 1) - 1; i >= 0; i--) this._down(i);\n }\n }\n\n push(item) {\n this.data.push(item);\n this.length++;\n this._up(this.length - 1);\n }\n\n pop() {\n if (this.length === 0) return undefined;\n\n const top = this.data[0];\n const bottom = this.data.pop();\n this.length--;\n\n if (this.length > 0) {\n this.data[0] = bottom;\n this._down(0);\n }\n\n return top;\n }\n\n peek() {\n return this.data[0];\n }\n\n _up(pos) {\n const {data, compare} = this;\n const item = data[pos];\n\n while (pos > 0) {\n const parent = (pos - 1) >> 1;\n const current = data[parent];\n if (compare(item, current) >= 0) break;\n data[pos] = current;\n pos = parent;\n }\n\n data[pos] = item;\n }\n\n _down(pos) {\n const {data, compare} = this;\n const halfLength = this.length >> 1;\n const item = data[pos];\n\n while (pos < halfLength) {\n let left = (pos << 1) + 1;\n let best = data[left];\n const right = left + 1;\n\n if (right < this.length && compare(data[right], best) < 0) {\n left = right;\n best = data[right];\n }\n if (compare(best, item) >= 0) break;\n\n data[pos] = best;\n pos = left;\n }\n\n data[pos] = item;\n }\n}\n\nfunction defaultCompare(a, b) {\n return a < b ? -1 : a > b ? 1 : 0;\n}\n\n\n\n// WEBPACK FOOTER //\n// C:/Dropbox/www/amcharts4dev/node_modules/tinyqueue/index.js","'use strict';\n\nvar Queue = require('tinyqueue');\n\nif (Queue.default) Queue = Queue.default; // temporary webpack fix\n\nmodule.exports = polylabel;\nmodule.exports.default = polylabel;\n\nfunction polylabel(polygon, precision, debug) {\n precision = precision || 1.0;\n\n // find the bounding box of the outer ring\n var minX, minY, maxX, maxY;\n for (var i = 0; i < polygon[0].length; i++) {\n var p = polygon[0][i];\n if (!i || p[0] < minX) minX = p[0];\n if (!i || p[1] < minY) minY = p[1];\n if (!i || p[0] > maxX) maxX = p[0];\n if (!i || p[1] > maxY) maxY = p[1];\n }\n\n var width = maxX - minX;\n var height = maxY - minY;\n var cellSize = Math.min(width, height);\n var h = cellSize / 2;\n\n if (cellSize === 0) {\n var degeneratePoleOfInaccessibility = [minX, minY];\n degeneratePoleOfInaccessibility.distance = 0;\n return degeneratePoleOfInaccessibility;\n }\n\n // a priority queue of cells in order of their \"potential\" (max distance to polygon)\n var cellQueue = new Queue(undefined, compareMax);\n\n // cover polygon with initial cells\n for (var x = minX; x < maxX; x += cellSize) {\n for (var y = minY; y < maxY; y += cellSize) {\n cellQueue.push(new Cell(x + h, y + h, h, polygon));\n }\n }\n\n // take centroid as the first best guess\n var bestCell = getCentroidCell(polygon);\n\n // special case for rectangular polygons\n var bboxCell = new Cell(minX + width / 2, minY + height / 2, 0, polygon);\n if (bboxCell.d > bestCell.d) bestCell = bboxCell;\n\n var numProbes = cellQueue.length;\n\n while (cellQueue.length) {\n // pick the most promising cell from the queue\n var cell = cellQueue.pop();\n\n // update the best cell if we found a better one\n if (cell.d > bestCell.d) {\n bestCell = cell;\n if (debug) console.log('found best %d after %d probes', Math.round(1e4 * cell.d) / 1e4, numProbes);\n }\n\n // do not drill down further if there's no chance of a better solution\n if (cell.max - bestCell.d <= precision) continue;\n\n // split the cell into four cells\n h = cell.h / 2;\n cellQueue.push(new Cell(cell.x - h, cell.y - h, h, polygon));\n cellQueue.push(new Cell(cell.x + h, cell.y - h, h, polygon));\n cellQueue.push(new Cell(cell.x - h, cell.y + h, h, polygon));\n cellQueue.push(new Cell(cell.x + h, cell.y + h, h, polygon));\n numProbes += 4;\n }\n\n if (debug) {\n console.log('num probes: ' + numProbes);\n console.log('best distance: ' + bestCell.d);\n }\n\n var poleOfInaccessibility = [bestCell.x, bestCell.y];\n poleOfInaccessibility.distance = bestCell.d;\n return poleOfInaccessibility;\n}\n\nfunction compareMax(a, b) {\n return b.max - a.max;\n}\n\nfunction Cell(x, y, h, polygon) {\n this.x = x; // cell center x\n this.y = y; // cell center y\n this.h = h; // half the cell size\n this.d = pointToPolygonDist(x, y, polygon); // distance from cell center to polygon\n this.max = this.d + this.h * Math.SQRT2; // max distance to polygon within a cell\n}\n\n// signed distance from point to polygon outline (negative if point is outside)\nfunction pointToPolygonDist(x, y, polygon) {\n var inside = false;\n var minDistSq = Infinity;\n\n for (var k = 0; k < polygon.length; k++) {\n var ring = polygon[k];\n\n for (var i = 0, len = ring.length, j = len - 1; i < len; j = i++) {\n var a = ring[i];\n var b = ring[j];\n\n if ((a[1] > y !== b[1] > y) &&\n (x < (b[0] - a[0]) * (y - a[1]) / (b[1] - a[1]) + a[0])) inside = !inside;\n\n minDistSq = Math.min(minDistSq, getSegDistSq(x, y, a, b));\n }\n }\n\n return minDistSq === 0 ? 0 : (inside ? 1 : -1) * Math.sqrt(minDistSq);\n}\n\n// get polygon centroid\nfunction getCentroidCell(polygon) {\n var area = 0;\n var x = 0;\n var y = 0;\n var points = polygon[0];\n\n for (var i = 0, len = points.length, j = len - 1; i < len; j = i++) {\n var a = points[i];\n var b = points[j];\n var f = a[0] * b[1] - b[0] * a[1];\n x += (a[0] + b[0]) * f;\n y += (a[1] + b[1]) * f;\n area += f * 3;\n }\n if (area === 0) return new Cell(points[0][0], points[0][1], 0, polygon);\n return new Cell(x / area, y / area, 0, polygon);\n}\n\n// get squared distance from a point to a segment\nfunction getSegDistSq(px, py, a, b) {\n\n var x = a[0];\n var y = a[1];\n var dx = b[0] - x;\n var dy = b[1] - y;\n\n if (dx !== 0 || dy !== 0) {\n\n var t = ((px - x) * dx + (py - y) * dy) / (dx * dx + dy * dy);\n\n if (t > 1) {\n x = b[0];\n y = b[1];\n\n } else if (t > 0) {\n x += dx * t;\n y += dy * t;\n }\n }\n\n dx = px - x;\n dy = py - y;\n\n return dx * dx + dy * dy;\n}\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// C:/Dropbox/www/amcharts4dev/node_modules/polylabel/polylabel.js\n// module id = o+vr\n// module chunks = cc1e"],"sourceRoot":""}