You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can reproduce this issue for example with the following numbers: Make a Pie Chart with 55, 21, 9, 15 which will result in 56%, 21%, 9%, 15% on the rendered chart.
Line 76 in pie.js is responsible, instead of
var visible_text = Math.ceil(percent) + '%';
it should be
var visible_text = Math.round(percent) + '%';
I would put in a pull request but unfortunately I don't have Git on this machine. I just thought I let you know in case somebody else runs into this issue.
Best
Chris
The text was updated successfully, but these errors were encountered:
Chris, thank you for posting this. I used these pie charts on a project almost a year ago and they contacted me today saying they changed the data and it was adding up to 101%. Your post saved me a lot of time.
Hi there, thank you for this great component!
You can reproduce this issue for example with the following numbers: Make a Pie Chart with 55, 21, 9, 15 which will result in 56%, 21%, 9%, 15% on the rendered chart.
Line 76 in pie.js is responsible, instead of
var visible_text = Math.ceil(percent) + '%';
it should be
var visible_text = Math.round(percent) + '%';
I would put in a pull request but unfortunately I don't have Git on this machine. I just thought I let you know in case somebody else runs into this issue.
Best
Chris
The text was updated successfully, but these errors were encountered: