I am trying to find out how to have different dataLabel colors for different columns.
Kind of like this:
- Code: Select all
plotOptions: {
column: {
dataLabels: {
enabled: true,
formatter: function() {
return this.point.name + (this.point.x === 0 ? '%' : 'pp');
},
color: this.point.x === 0 ? '#005712' : '#CC0000' // ** does not work (obviously) **
},
}
},
I also tried dataLabels under series.data, but no luck there either.
- Code: Select all
series: [{
data: [
{y: data.valueActual, low: 0, name: data.valueActual, color: {
linearGradient: [0, 0, 0, data.valueActual],
stops: [
[0, '#CCCCCC'],
[1, '#FFFFFF']
]},
dataLabels: {
color: '#00FF00' // ** seems to be ignored **
}
},
Thanks.