-
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
Axis default positions #3893
Axis default positions #3893
Conversation
2befa84
to
b6ffd5b
Compare
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.
Looks good, is unit tests pertinent for this change?
src/core/core.controller.js
Outdated
@@ -240,6 +249,11 @@ module.exports = function(Chart) { | |||
return; | |||
} | |||
|
|||
if (positionIsHorizontal(scaleOptions.position) !== |
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.
[minor] can we keep the condition on the same line, quite confusing when reading :) ?
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.
Sure, I will make that change
ba4b76f
to
0598832
Compare
I added a unit test to cover this. |
0598832
to
202e439
Compare
+1 to merge! what's the reason unit tests values required adjustments? |
Previously, there were 3 axes in the chart in that test (1 on the x, 1 on the y at position 'left' and one on the y at position 'bottom' so I cleaned it up to have only 2 and mimic the old fitting but the sizes changed slightly |
@etimberg any idea on how i can get the axis labels to render with the x-axis instead of top or bottom? |
This PR contains 2 changes.
Example: