mapviewer: Support custom markers (divIcons)
Summary
Integrate text labels on the map
Benefits
User can see text labels on the map (easy to identify).
Usage
Examples
(Add code samples of usage, with expected output)
var my_icon2 = L.divIcon({
className:'current-location-icon2',
html:'<span class="label_text text-black '+sublayer.feature.properties.Id+'">'+sublayer.feature.properties.BLOCK_NAME+'</span>',
iconAnchor:[0,0],
iconSize:null,
popupAnchor:[0,0]
})
L.marker([sublayer.getCenter().lat, sublayer.getCenter().lng], {radius: 5,
icon : my_icon2, color:'blue',opacity:1,fillColor: 'blue',fillOpacity:.4 ,className : "map_circle2"}).addTo(map)
Depends on the layer centroid, added text on the map.