You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Lumped fixes for #3002 and #3003 into one PR, since they touch the same code.
Issue with fill in stackgroups #3003 had two related components. First, which trace is "next" when we fill between two traces (and if there even is a next or should we fill to zero), stacked or otherwise, needs to take account of stackgroup. The "next" trace must be in the same stack group, or no stack group. Second, once you've done this, it doesn't make much sense to preserve the trace ordering as it is in gd.data exactly. Traces in the same stack group, or that fill to each other, need to be in consecutive order - or you can get weird effects like Issue with fill in stackgroups #3003 (comment). As mentioned there, I chose to push traces only backward to meet the first in their stack, but otherwise to preserve the existing order as much as possible. The new mock demonstrates this.
Error when deleting traces with stackgaps #3002 pointed out that we were actually redrawing points even if we were about to remove their trace entirely! So not only does this work now, but deleting scatter traces will be faster in general now.
The reason will be displayed to describe this comment to others. Learn more.
@etpinard it doesn't seem like animations can remove traces, is that correct? That's what it looks like, since I don't see a join.exit() associated with them (since isFullReplot = !transitionOpts)... yet the comment above implies that you can add traces:
// Must run the selection again since otherwise enters/updates get grouped together// and these get executed out of order. Except we need them in order!
So... do I need to worry about animations deleting traces or not?
@etpinard 3rd time's a charm, but the intermittent error in test-jasmine2 (that came in with the context loss event PR?) has been rearing its ugly head...
First, which trace is "next" when we fill between two traces (and if there even is a next or should we fill to zero), stacked or otherwise, needs to take account of stackgroup. The "next" trace must be in the same stack group, or no stack group. Second, once you've done this, it doesn't make much sense to preserve the trace ordering as it is in gd.data exactly. Traces in the same stack group, or that fill to each other, need to be in consecutive order - or you can get weird effects like #3003 (comment). As mentioned there, I chose to push traces only backward to meet the first in their stack, but otherwise to preserve the existing order as much as possible. The new mock demonstrates this.
Nice solution! Would you mind adding a few words about this behavior in the fill attribute description?
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
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.
Lumped fixes for #3002 and #3003 into one PR, since they touch the same code.
stackgroup. The "next" trace must be in the same stack group, or no stack group. Second, once you've done this, it doesn't make much sense to preserve the trace ordering as it is ingd.dataexactly. Traces in the same stack group, or that fill to each other, need to be in consecutive order - or you can get weird effects like Issue with fill in stackgroups #3003 (comment). As mentioned there, I chose to push traces only backward to meet the first in their stack, but otherwise to preserve the existing order as much as possible. The new mock demonstrates this.