-
Notifications
You must be signed in to change notification settings - Fork 760
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug #442 - Border Color #462
base: master
Are you sure you want to change the base?
Bug #442 - Border Color #462
Conversation
…colors instead of just the two hard coded bfore
…the broken colors bug
}] | ||
}; | ||
colors.map(function (color) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
map returns a newly created array which is not needed here, so use forEach
instead.
Thanks a ton for your pull request and taking the time to fix this issue! While I like that it fixes the issue, it's a bit tricky as it radically changes the color scheme for the default colors, so it's almost like a breaking change. I wonder if there is another way, is it one of the properties that is missing specifically? |
Is this issue going to get fixed? |
@jsd219 I like that it fixes the border issue but on the other hand, it would be like a breaking change for users to change the color scheme. Also there are comments that would need to be addressed and need to be rebased. A different fix that doesn't break the color scheme would be my preference. |
PR fixes Bug #442
Description of change
This PR fixes the issue related to border colors not overwriting for pie and doughnut graphs. The issue was that the pie and doughnut graphs invoke the getData method which seems to have only hard coded 2 color values when there are many others. The fix was to instead look through all the keys of the colors and push them into the dataset.
Notice that I uploaded 3 newer images. Why? If you notice in the old images, the alpha for the pie and doughnut graphs appear to be 1.0, but that is not the default behavior as defined here https://github.com/jtblin/angular-chart.js/blob/master/angular-chart.js#L242. The PR fixes the bug which allows the backgroundColor to be set correctly vs before it was not.