var ctx = document.getElementById('myChart-1').getContext('2d'); var chart = new Chart(ctx, { type: 'pie', data: { labels: [ 'Міське', 'Сільське' ], datasets: [{ label: false, backgroundColor: [ '#42a5f5', '#1565c0' ], data: [ 600000, 770000 ] }] }, options: { responsive: true, // legend: { position: 'left', align: 'center' }, tooltips: { mode: 'label', callbacks: { label: function(tooltipItem, data) { var indice = tooltipItem.index; return data.labels[indice] +': '+data.datasets[0].data[indice] + ''; } } }, } });