Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Mixed chart #5134
Mixed chart #5134
Changes from 8 commits
619d1f6
ee8e195
76b13d1
cd75f9b
1a32e89
7cdd680
a01f580
042920e
05669ed
2f9727b
6e84627
de80075
f24d979
8ea9ee6
32f14aa
892dc15
25119d4
780f4eb
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
What's the reason for overriding and returning false here? Shouldn't that have already happened?
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.
From what i understand, with mixed chart, the default style applied is the style of the 'main' chart.
And for now, only
bar
orline
are valid main types.So the option
showLines
is never set tofalse
. You'd have to do it manually in the child chart.You can try commenting the line n°8187 and n°19040 in this codepen
And you can check the console for
Chart.config.data.datasets[0].showLine
.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.
But now that I think about it, is being able to show lines in a scatter chart a wanted feature ?
If so, then this overriding would break it.
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.
I think lines on a scatter chart is something that should be possible and its currently the default behaviour
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.
So does that mean a test should be added via another PR to make sure it stays that way in the future ?
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.
I would think adding a test to ensure that a scatter chart can optionally use a line or not is a good idea. @simonbrunel thoughts?
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.
I don't see why scatter charts couldn't display lines, so yes these
lineEnabled
changes should be reverted. We could add a test indeed, but in a different PR.