Generates per-region CSS selectors for a map series read as a choropleth.
MAIDR's ChoroplethTrace indexes its selector list by the order the layer
declared its regions — the grid it walks is in latitude order, and source
takes it back to the declaration — so the list has to run in that order and
hold exactly one element per region. Highcharts draws a shape for every
point including the ones with no value, which the layer leaves out, so
document order is one entry longer than the payload on any map with a gap
in it. The adapter therefore stamps data-maidr-region-index="N" onto each
announced region's shape (see stampPointIndices in adapter.ts) and
these selectors address the stamp.
A region Highcharts did not draw has no element to stamp, so its selector
matches nothing and ChoroplethTrace withdraws the layer's highlighting
rather than shading a neighbouring country for the rest of the session.
Generates per-region CSS selectors for a
mapseries read as a choropleth.MAIDR's
ChoroplethTraceindexes its selector list by the order the layer declared its regions — the grid it walks is in latitude order, andsourcetakes it back to the declaration — so the list has to run in that order and hold exactly one element per region. Highcharts draws a shape for every point including the ones with no value, which the layer leaves out, so document order is one entry longer than the payload on any map with a gap in it. The adapter therefore stampsdata-maidr-region-index="N"onto each announced region's shape (seestampPointIndicesin adapter.ts) and these selectors address the stamp.A region Highcharts did not draw has no element to stamp, so its selector matches nothing and
ChoroplethTracewithdraws the layer's highlighting rather than shading a neighbouring country for the rest of the session.