In my line chart I wanted to when I hovered the mouse on the chart line when the caption appeared, and it had a caption. This is only possible by filling the array of labels, but it appears below the graph, on the "X" axis the names, and I do not want to, I just want the titles in the captions.
Follow the code:
angular.module("app", ["chart.js"]).controller("LineCtrl", function($scope) {
$scope.labels = ["Titulo 1", "Titulo 2", "Titulo 3", "Titulo 4", "Titulo 5", "Titulo 6", "Titulo 7"];
$scope.series = ['Legenda 1', 'Legenda 2'];
$scope.data = [
[65, 59, 80, 81, 56, 55, 40],
[28, 48, 40, 19, 86, 27, 90]
];
$scope.onClick = function(points, evt) {
console.log(points, evt);
};
});
In this way, it generates a title on the captions when mouseover, but the names appear below the graph, I wanted the names not appear below the graph, only in the title even when hovering the mouse, how would it look?
Reference: link
jsfiddle : link