Next
Update
Prev

The HTML new line tag, <br> can be used in the JavaScript function to wrap a label text.

...
  <MapSeries ... labelJsFunction="labelFunction" ... >
    ...
  </MapSeries>
...

function labelFunction(seriesId, code, label, data) {
  if (code == "9000") {
    return {"text":label+"<br>Excellent", "color":"#FF0000", "fontSize":"20", "fontWeight":"bold", "lineHeight":10}}
  else if ((code >= "5000" && code <= "8000") || code == "1000" || code == "11000")
    return {"text":label+"<br>Average", "color":"#0000FF"};
  else if (code == "20000")	
    return {"text":" "};
  else if (code == "21000")	
    return {"text":" "};
  else if (code == "30000")
    return {"text":" "};
  else if (code == "37000")
    return {"text":" "};
  else if (code == "39000")
    return {"text":" "};
  else if (code == "45000")	
    return {"text":" "};
  else if (code == "48000")	
    return {"text":" "};
  else if (code == "51000")
    return {"text":" "};
		
  return label;
}

© 2017 KoolChart. All rights reserved.