I'm using primeng on an angular and I want to create a bar graph where the last 2 horizontal bars are colored differently.
At the moment the last 2 are being wrapped around and interpreted as dogs and cats My question is, how would I edit the graph so that the two orange bars on dog and cat are on tiger and lion?
For some reason StackOverflow is not letting me post a picture so here is the link to an image hosting site I uploaded the example to: https://ibb.co/jZyxddC
component code:
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-status-logs-graph',
templateUrl: './status-logs-graph.component.html',
styleUrls: ['./status-logs-graph.component.scss']
})
export class StatusLogsGraphComponent implements OnInit {
basicData: any;
basicOptions: any;
constructor() {
this.basicData = {
labels: ['dog', 'cat', 'hamster', 'lizard', 'tiger', 'lion'],
datasets: [
{
label: 'Domestic Animals',
backgroundColor: '#42A5F5',
data: [ 32, 54, 21, 11]
},
{
label: 'Wild Animals',
backgroundColor: '#FFA726',
data: [28, 48]
}
]
};
}
ngOnInit(): void {
}
}