Preserve options in svg graph links #2132
Merged
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.
Description
Include options from url hash in svg graph node links.
Motivation and Context
When clicking on the nodes in an svg graph, a graph will load with that node as the root but with hide done and show upstream dependencies unset. This can be very annoying when you suddenly have to load a much larger graph or your graph flips orientation.
In order to preserve these and any future options, we pass the hash with taskId stripped out of it into the dependency graph so it can use that as a basis for the node links. This preserves the options present when the graph was created, which should match the current options on the
page.
D3 graphs also suffer from the same bug, but they are not addressed by this change.
Have you tested this? If so, how?
Ran locally and in production. Willing to write tests once I learn how.