Home Forums Chart Support how to add tooltip color Reply To: how to add tooltip color

#38790

@joinfurther,

You can pass the color within single quote to set the font-color of the text shown in tooltip as shown in the code-snippet below:

contentFormatter: function (e) {
    var content = " ";
    for (var i = 0; i < e.entries.length; i++) {
       content += e.entries[i].dataSeries.name + " " + "<strong style='color: red;'>" + e.entries[i].dataPoint.y + "</strong>";
       content += "<br/>";
    }
    return content;
}


Thangaraj Raman
Team CanvasJS