vue-chartjs icon indicating copy to clipboard operation
vue-chartjs copied to clipboard

[Bug]: Incorrect animation on data change on two or more datasets in doughnut chart

Open Toverbal opened this issue 1 year ago • 0 comments

Would you like to work on a fix?

  • [ ] Check this if you would like to implement a PR, we are more than happy to help you go through the process.

Current and expected behavior

When implementing a doughnut chart with two or more datasets, changing the dataset data will animate the first dataset correctly, but completely redraw the second and further.

I made a reproduction sample on stackblitz, it randomizes the data of the two datasets every 3 seconds. When the data is updated, the inner dataset will be fully redrawn, while the outer one is updated correctly.

My hunch is that it is a vue-chartjs issue, since it seems to be working with chartjs, see https://www.chartjs.org/docs/latest/samples/other-charts/doughnut.html (click 'Add dataset' and then 'Randomize').

Reproduction

https://stackblitz.com/edit/github-dkpthv-jjntw2?file=src%2FchartConfig.ts

chart.js version

v4.4.0

vue-chartjs version

v5.2.0

Possible solution

No response

Toverbal avatar Dec 02 '23 15:12 Toverbal