fix: stack as percentage with 0 or null values#618
Merged
markov00 merged 2 commits intoelastic:masterfrom Apr 3, 2020
Merged
Conversation
This commit fix a regression related to the rendering of stacked area/bar charts where Y values are 0 or null and the stack is configured as percentage fix elastic#617
Codecov Report
@@ Coverage Diff @@
## master #618 +/- ##
==========================================
- Coverage 70.79% 70.63% -0.16%
==========================================
Files 220 220
Lines 6409 6439 +30
Branches 1224 1229 +5
==========================================
+ Hits 4537 4548 +11
- Misses 1853 1872 +19
Partials 19 19
Continue to review full report at Codecov.
|
nickofthyme
approved these changes
Apr 3, 2020
rshen91
approved these changes
Apr 3, 2020
Contributor
rshen91
left a comment
There was a problem hiding this comment.
LGTM checked out locally on Chrome - thanks for writing really clear tests and adding the new story in storybook
markov00
added a commit
to markov00/elastic-charts
that referenced
this pull request
Apr 3, 2020
This commit fix a regression related to the rendering of stacked area/bar charts where Y values are 0 or null and the stack is configured as percentage fix elastic#617
markov00
added a commit
that referenced
this pull request
Apr 6, 2020
markov00
pushed a commit
that referenced
this pull request
Apr 6, 2020
Collaborator
Author
|
🎉 This PR is included in version 18.2.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
markov00
added a commit
to markov00/elastic-charts
that referenced
this pull request
Apr 8, 2020
This commit review the work done in elastic#618 to fix the following case: if we are stacking areas in percentage mode and the values for all series are 0 we shall use 0% as value for each point in that bucket. In the aforementioned PR we were handling that case as null, completely disconnecting the previous data points from the following ones on the chart.
2 tasks
markov00
added a commit
that referenced
this pull request
Apr 9, 2020
This commit review the work done in #618 to fix the following case: if we are stacking areas in percentage mode and the values for all series are 0 we shall use 0% as value for each point in that bucket. In the aforementioned PR we were handling that case as null, completely disconnecting the previous data points from the following ones on the chart.
2 tasks
AMoo-Miki
pushed a commit
to AMoo-Miki/OpenSearch-Dashboards
that referenced
this pull request
Feb 10, 2022
## [18.2.1](elastic/elastic-charts@v18.2.0...v18.2.1) (2020-04-07) ### Bug Fixes * stack as percentage with 0 or null values ([opensearch-project#618](elastic/elastic-charts#618)) ([9de7b60](elastic/elastic-charts@9de7b60)), closes [opensearch-project#617](elastic/elastic-charts#617)
This comment was marked as spam.
This comment was marked as spam.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.


Summary
This commit fix a regression related to the rendering of stacked area/bar charts where Y values are 0 or null and the stack is configured as percentage.
A new snapshot test was also added to cover that case
fix #617
Checklist
Delete any items that are not applicable to this PR.