mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-17 17:14:18 +02:00
Fixed: StackedChart colors only showing on page load
This commit is contained in:
@@ -44,7 +44,13 @@ class StackedBarChart extends Component {
|
||||
|
||||
componentDidUpdate() {
|
||||
this.myChart.data.labels = this.props.data.labels;
|
||||
this.myChart.data.datasets = this.props.data.datasets;
|
||||
this.myChart.data.datasets = this.props.data.datasets.map((d, index) => {
|
||||
return {
|
||||
label: d.label,
|
||||
data: d.data,
|
||||
backgroundColor: colors.chartColors[index]
|
||||
};
|
||||
});
|
||||
this.myChart.update();
|
||||
}
|
||||
|
||||
|
@@ -39,8 +39,6 @@ function getTotalRequestsData(indexerStats) {
|
||||
]
|
||||
};
|
||||
|
||||
console.log(data);
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user