-
Notifications
You must be signed in to change notification settings - Fork 4.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
propagate combo stacking to area and bar charts #42600
propagate combo stacking to area and bar charts #42600
Conversation
e17fa52
to
a992419
Compare
|
1ebd298
to
c233fd8
Compare
e812eaa
to
f23eb15
Compare
f23eb15
to
5a3ae84
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.
🙌
@@ -363,13 +368,15 @@ function getStackedValueTransformFunction( | |||
}, 0); | |||
const rawTotal = rawBelowTotal + getNumberOrZero(datum[seriesDataKey]); | |||
|
|||
const transformedRawBelowTotal = valueTransform(rawBelowTotal) ?? 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.
Would be better on line 377 so it's underneath the comment explaining that step.
@@ -577,18 +580,5 @@ describe("dataset transform functions", () => { | |||
expect(result[1][X_AXIS_DATA_KEY]).toBe(5); | |||
expect(result[2][X_AXIS_DATA_KEY]).toBe(1000); | |||
}); | |||
|
|||
it("handles empty datasets without errors", () => { |
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 context for this test being deleted?
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.
It looks like this test here is the result of some rebase in the past because it was in the describe("getTransformedDataset", () => {})
group while testing applyVisualizationSettingsDataTransformations
which is a newer name. And there is already a "should work on empty datasets" test of applyVisualizationSettingsDataTransformations
* propagate combo stacking to area and bar charts * enable combo stacking for bar/area charts, fix data transform * fix types, specs * fix y-axis extents calculations * remove spec that tested the removed control, update specs, update test data
* combo stacked chart * spec * remove irrelevant spec * combo stacking * fix selecting y-axis on stacked charts * snapshot * linter, specs, types * propagate combo stacking to area and bar charts (#42600) * propagate combo stacking to area and bar charts * enable combo stacking for bar/area charts, fix data transform * fix types, specs * fix y-axis extents calculations * remove spec that tested the removed control, update specs, update test data * review * show show data values setting on normalized charts that have a line series * fixes
* move series data label formatters to the model - TODO: move stacked data label formatters to the model * combo stacked chart * spec * remove irrelevant spec * combo stacking * fix selecting y-axis on stacked charts * snapshot * linter, specs, types * propagate combo stacking to area and bar charts * enable combo stacking for bar/area charts, fix data transform * fix types, specs * fix y-axis extents calculations * remove spec that tested the removed control, update specs, update test data * propagate combo stacking to area and bar charts (#42600) * propagate combo stacking to area and bar charts * enable combo stacking for bar/area charts, fix data transform * fix types, specs * fix y-axis extents calculations * remove spec that tested the removed control, update specs, update test data * review * remove unused formatting options parameter * move stacked labels formatter to model * fix stacked combo chart label display for non-stacked lines * combo stacked chart * spec * remove irrelevant spec * combo stacking * fix selecting y-axis on stacked charts * snapshot * linter, specs, types * propagate combo stacking to area and bar charts (#42600) * propagate combo stacking to area and bar charts * enable combo stacking for bar/area charts, fix data transform * fix types, specs * fix y-axis extents calculations * remove spec that tested the removed control, update specs, update test data * review * fix waterfall chart labels --------- Co-authored-by: Aleksandr Lesnenko <alxnddr@gmail.com> Co-authored-by: Aleksandr Lesnenko <alxnddr@users.noreply.github.com>
Epic #41976
Description
This PR enables creating stacked combo charts for Bar/Area visualizations. It requires removing
Stacked chart type
which allowed to override area/bar chart type:It was a convenient way to switch between area/bar appearance although redundant. Now this setting does not make sense since it is possible to have both area and bar stacks on the same chart.
This PR also fixes the issue on non-linear y-axis scales when some series were stacked and others don't.
How to verify
Demo
Checklist