Trellis chart x categories values are not displaying correctly in Highcharts
Trellis chart x categories values are not displaying correctly in Highcharts
I am working on the Trellis chart highchart.
and I have categories values with long names,for that categories value should start from first letter but its showing from the middle of the
categories value to last,
actual title: Appleswwwwwwwwwwwe
now its showing like: wwwwwwwwe
But i need to show the title with ellipsis like
Appleswee...
xAxis: {
categories: ['Appleswwwwwwwwwwwe', 'Pewerttttttttttttars', 'Oranges', 'Bananas'],
labels: {
enabled: i === 0
}
},
Here is the jsFiddle
can anyone help me ?
1 Answer
1
Its working, I used below code from this jsfiddle
label : {
formatter: function () {
var text = this.value,
formatted = text.length > 25 ? text.substring(0, 25) + '...': text;
return formatted ;
}
}
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.