-
Notifications
You must be signed in to change notification settings - Fork 28
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
fix(core): Flipped y-axis stacked bar chart #1042
Conversation
@@ -1011,7 +1011,7 @@ const factory: PluginTrackFactory<Tile, GoslingTrackOptions> = (HGC, context, op | |||
|
|||
// Replace width and height information with the actual values for responsive encoding | |||
const [trackWidth, trackHeight] = this.dimensions; // actual size of a track | |||
const axisSize = IsXAxis(resolvedSpec) ? HIGLASS_AXIS_SIZE : 0; // Why the axis size must be added here? | |||
const axisSize = IsXAxis(resolvedSpec) && this.options.spec.layout === 'linear' ? HIGLASS_AXIS_SIZE : 0; // Why the axis size must be added here? |
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.
Circular tracks were receiving the incorrect track height because height was being added here.
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.
Ah, good catch.
(isFlippedY && y - rowHeight >= 0) || | ||
(!isFlippedY && y <= 0) |
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.
Add some extra conditions to keep incorrect draws from occurring
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.
Thank you for the fix!!
I will patch gosling.js once this is merged! |
Oh, actually will increase the minor version considering #1044 |
Fix #1041
Toward #
Change List
Before:
After:
Circular layout
Before:
After:
Checklist