I'm making a Chart.js in angular and I need to put the percent (%) at the end of each tooltip where it shows the value in the chart.
Follow my chart code:
Html:
<canvas class="chart chart-doughnut" chart-data="vm.data" chart-labels="vm.labels" chart-colors="vm.colors" chart-options="vm.options" ng-init="vm.chart()"></canvas>
JS:
vm.chart = () => {
vm.labels = ["D1", "VC1", "Internacional", "À cobrar", "0300", "Gratuita", "Locais"];
vm.colors = [ '#f36e20', '#8aca7b', '#0bc4df', '#272343', '#389223', '#f1a80a', '#1e75eb'];
vm.data = [10, 10, 20, 10, 10, 10, 30];
vm.options = {
}
}
Does anyone know if it is in the options that I enter this option?
The vm.data only accepts integers, maybe you should have some method of entering decimal values and with them the% together.