How do you have each bar in a bar chart have a different color using angular-chartjs on the chartjs 2.0 branch?
My canvas looks like this:
<canvas class="chart chart-bar"
chart-data="GBCC.setData"
chart-labels="GBCC.labels"
chart-options="GBCC.options"
chart-colors="GBCC.colors"
height="68"
width="300">
</canvas>
My GBCC controller looks like this:
this.labels = ['hello', 'world', 'foobar'];
this.setData = [[50, 20, 95]];
this.colors = [
'#DCDCDC', // light grey
'#F7464A', // red
'#46BFBD', // green
];
this.options = {
scales: {
yAxes: [{
display: true,
ticks: {
beginAtZero: true,
min: 0,
max: 100,
stepSize: 20
}
}]
}
};
It will change all the bars to the first color in the array, but not use the other colors. Does any one know how to do this?