Hi I am trying bold the labels as per the attached image in the the code base with calculation with percentage as shown
Asked
Active
Viewed 207 times
1 Answers
0
Try use dataLabels.formatter to edit dataLabels, and style inside CSS but remember to set dataLabels.useHTML.
plotOptions: {
sankey: {
dataLabels: {
useHTML: true,
formatter: function() {
let chart = this,
weight = chart.point.weight;
return `Weight: <span>${weight}</span>`
}
},
}
},
Demo:
https://codepen.io/sebastian-hajdus/pen/BarjMap
API References:
https://api.highcharts.com/highcharts/series.sankey.dataLabels.formatter https://api.highcharts.com/highcharts/series.sankey.dataLabels.useHTML

Sebastian Hajdus
- 1,422
- 1
- 5
- 14