fix(discover): Always use area charts with "Previous Period" #88058
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.
Fixes a nasty bug with Discover. If someone chooses multiple Y axes and sets the display to "Previous Period", they see something very weird: the "previous period" series are stacked so they have an incorrect position on the chart. This happens because "previous period" values are hard-coded in multiple places to always stack. They really only work when shown next to stacked area or bar charts!
This is very deep down, and hard to rip out. Instead, to fix the issue for the user in question, I'm makes it so "Previous Period" always uses stacked area charts. This has its own problems, but Discover isn't long for this world. Newer UIs allow users to customize the visualization on their own terms instead of using heuristics on the data.
Closes DAIN-122.
Closes #87969
e.g.,