Closed kjrhody closed 8 years ago
I cannot get labels to appear. My current code is:
$(document).ready(function(){ $('#map').usmap({ showLabels: true, stateStyles: { fill: '#F0EFED', 'stroke': '#60605f' }, stateHoverStyles: { fill: '#d3e7fb' }, stateSpecificHoverStyles: { 'RI': {fill: 'red'}, 'MA': {fill: 'red'} }, // The click action click: function(event, data) { window.open("https://someurl.com"+data.name); } }); });
Edit:
So it appears that the showLabels: true property actually refers to the block labels for the small northeastern states. By setting it to false, those labels disappear. Is there any way to show labels for the each state in the US?
showLabels: true
false
Sorry, looks like there is a great patch for it here
https://github.com/DaddyMacCadillac/us-map/commit/db16541904ac5c5993d7ef040fc9053abba05c83#diff-90ecb4d62200685c1393e1ddf9e96373
I cannot get labels to appear. My current code is:
Edit:
So it appears that the
showLabels: true
property actually refers to the block labels for the small northeastern states. By setting it tofalse
, those labels disappear. Is there any way to show labels for the each state in the US?