[Pro] Add labels inside round markers

You are here:

Altough the plugin doesn’t support this feature directly, it’s possible to add small text like numbers or letters inside the round markers.

To do this, you’ll need to add the number of letter to the value field of your marker.

[Pro] Add labels inside round markers

Then, in the custom JS field of the map, add the following code:

function igm_custom_filter_XXX(data) {

    data.roundMarkers = data.roundMarkers.map(function(marker) {
	marker.label = marker.value;
        return marker;
    });

    return data;

}

You’ll need to replace XXX with the ID of your map. This will populate the hidden label property of your marker which will auto populate inside the marker.

Consider there isn’t much space inside the marker, so this hack works better for single numbers of letters.

Posted by Carlos Moreira

Lead developer of Interactive Geo Maps plugin.