-
Notifications
You must be signed in to change notification settings - Fork 11.9k
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
[2.9] Incorrect labels when using object dataset #7854
Conversation
i would like to contribute |
You'll need to find a way to get the |
When using object datasets, labels are displayed incorrect because they are retrieved based on item index instead of the corresponding x or y property. Fixes chartjs#7839
3a26c62
to
94dcfde
Compare
Hello! I pushed the changes to make |
Isn't the same possible by just configuring the right mode ('x' or 'y')? |
Hi, I made a jsfiddle reproducing the issue. When you hover the point, the tooltip shows the incorrect month; that happens because it looks for the label data using the item index instead of the x / y property. Could you elaborate on the mode configuration you mentioned? |
I was referring to the changes to the interaction modes, that seems unneeded to me. See: https://jsfiddle.net/kc26bnzy/ where I just replaced the |
That's an interesting solution, but isn't it more like a workaround? With this PR, we would have exactly the same result out of the box |
Let me try to be more clear: Why is the change needed for |
When using object datasets, labels are displayed incorrectly because they are retrieved based on item index instead of the corresponding x or y property.
Also I created test cases for this issue.
Fixes #7839