-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
feat(dashboards): Allow constraining the Y axis range to data min and max in TimeSeriesWidgetVisualization
#90247
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
Merged
gggritso
merged 4 commits into
master
from
georgegritsouk/dain-377-allow-setting-automatic-y-axis-min
May 23, 2025
Merged
feat(dashboards): Allow constraining the Y axis range to data min and max in TimeSeriesWidgetVisualization
#90247
gggritso
merged 4 commits into
master
from
georgegritsouk/dain-377-allow-setting-automatic-y-axis-min
May 23, 2025
Conversation
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
@billyvg this PR has a story with a simple repro case for the bubbles limitation. In the third chart in the section, you can click the "Releases" legend item to hide the bubbles and the Y axis will be constrained correctly. |
billyvg
added a commit
that referenced
this pull request
May 20, 2025
By default, release bubbles will use the default y-axis. This generally works except when the chart does not start at "y=0" as the bubbles are hard-coded to show below "y=0". With this change, the `useReleaseBubbles` hook returns a yaxis object that the hook consumer can use to pass to echarts -- you will also need to configure `yaxisIndex` to tell the release bubbles series which yaxis to use. This works by adding a new yaxis to decouple release bubbles series from the default yaxis. This new yaxis is configured to be hidden. This also works if you ignore the returned y-axis object and don't specify a `yaxisIndex` since it will use the default yaxis (assuming it starts at 0). Unblocks #90247
andrewshie-sentry
pushed a commit
that referenced
this pull request
May 20, 2025
By default, release bubbles will use the default y-axis. This generally works except when the chart does not start at "y=0" as the bubbles are hard-coded to show below "y=0". With this change, the `useReleaseBubbles` hook returns a yaxis object that the hook consumer can use to pass to echarts -- you will also need to configure `yaxisIndex` to tell the release bubbles series which yaxis to use. This works by adding a new yaxis to decouple release bubbles series from the default yaxis. This new yaxis is configured to be hidden. This also works if you ignore the returned y-axis object and don't specify a `yaxisIndex` since it will use the default yaxis (assuming it starts at 0). Unblocks #90247
billyvg
approved these changes
May 23, 2025
Codecov ReportAttention: Patch coverage is ✅ All tests successful. No failed tests found.
Additional details and impacted files@@ Coverage Diff @@
## master #90247 +/- ##
==========================================
+ Coverage 85.66% 87.71% +2.05%
==========================================
Files 10174 10247 +73
Lines 583386 577620 -5766
Branches 22594 22696 +102
==========================================
+ Hits 499733 506676 +6943
+ Misses 83201 70501 -12700
+ Partials 452 443 -9 |
narsaynorath
approved these changes
May 23, 2025
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.
Closes DAIN-377: Allow setting automatic Y axis min
except for a huge caveat with release bubbles.Adds a new prop to
TimeSeriesWidgetVisualization
. IfaxisRange
is set to"axisRange"
, the Y axis doesn't start at 0, it starts at the data min. The story has an explanation of when this is useful and how to use it.e.g.,

These two charts plot the same data series!