Home › Forums › Feature Requests & Feedback › Add tooltip on legend labels › Reply To: Add tooltip on legend labels
The following works for adding tooltip:
itemmouseover: function (e) {
$(e.chart._canvasJSContainer).attr("title", "My custom toolip");
console.log('mouseover');
e.chart.legend.fontColor = 'orange';
e.chart.legend.backgroundColor = 'blue';
e.chart.legend.borderColor = 'red';
e.chart.legend.borderThickness = 3;
e.chart.legend.fontStyle = 'italic';
e.chart.legend.fontWeight = 'bold';
e.chart.render();
},
itemmouseout: function (e) {
$(e.chart._canvasJSContainer).removeAttr("title");
console.log('mouseout');
e.chart.legend.fontColor = 'black';
e.chart.legend.backgroundColor = 'transparent';
e.chart.legend.borderColor = 'transparent';
e.chart.legend.borderThickness = 0;
e.chart.legend.fontStyle = 'normal';
e.chart.legend.fontWeight = 'normal';
e.chart.render();
}
But, doesn’t work for changing the color/style/border/whatever of the series label. Any tips on how to get that to work?