A Massive Maps Upgrade in amCharts 4.3
The just-released amCharts 4.3 includes a slew of exciting updates to maps functionality. From new projections to the additional rotation and panning features and more, the new release delivers a bunch of exciting goodies for those investing in map charts.
You can start using all of these features right away. Or check the updated Anatomy of Map Chart article in the documentation for technical details.
Here’s the complete list of what was added, changed and fixed in version 4.3:
Added
MapChart
can now use any projection supported by d3-geo.Projection.d3Projection
property added and you can set any d3-geo projection using it, like: mapChart.projection.d3Projection = am4maps.d3geo.geoConicEquidistant();
. - Albers, AlbersUsa, AzimuthalEqualArea, EqualEarth, NaturalEarth1, Stereographic projection classes added (use them regularly like:
mapChart.projection = new EqualEarth()
). deltaLatitude
,deltaGamma
addedto MapChart
. Together with alreadyexisting deltaLongitude
allows rotating maps in any possible direction.panBehavior
property addedto MapChart
. Values: “move” (default), “rotateLat “, “rotateLong”, “rotateLongLat”. Indicate what should happen whenmap is dragged.ignoreBounds
addedto MapSeries
. Specifies if this series must be included when calculating bounds of the map.calculateVisualCenter
addedto MapPolygonSeries
. Specifies if map polygons should calculate their visual center. Visual center is good for placing labels.visualLongitude
and visualLatitude
getters addedto MapPolygon
. They return coordinatesif calculateVisualCenter
of series is setto true
. You can also set them manually.getCircle()
and getBackground()
methods addedto MapUtils
. Graticule
and GraticuleSeries
classed added. Those allow creating graticules (map grid).backgroundSeries
added to MapChart. Allows creating a map-shaped background fill.
Changed
Engine behind rendering of maps was changed to use d3-geo.While the change should beackwards compatible, beware of and report any issues.day-night-map
and morphing-countries
demos we changed to work properly withnew version.- When adding a
HeatLegend
to MapChart
its valign = "bottom"
is no longer set by default. Set it explicitly if you needlegend to bottom-aligned.
Fixed
rtl
setting was not being inherited properly.- Fixed RTL behavior for labels.
- Disposing a hovered chart with scroll pan enabled used to leave whole document with disabled wheel scroll.