This repository was archived by the owner on Jun 25, 2020. It is now read-only.
fix(forcedirected.js): make force directed graph zoomable and pannable#393
Open
IndexOutOfRange wants to merge 2 commits intoapache-superset:masterfrom
Open
fix(forcedirected.js): make force directed graph zoomable and pannable#393IndexOutOfRange wants to merge 2 commits intoapache-superset:masterfrom
IndexOutOfRange wants to merge 2 commits intoapache-superset:masterfrom
Conversation
|
Deploy preview for superset-ui-plugins ready! Built with commit d7ba315 |
Codecov Report
@@ Coverage Diff @@
## master #393 +/- ##
=========================================
+ Coverage 1.48% 2.78% +1.29%
=========================================
Files 185 186 +1
Lines 5805 5827 +22
Branches 370 372 +2
=========================================
+ Hits 86 162 +76
+ Misses 5707 5638 -69
- Partials 12 27 +15
Continue to review full report at Codecov.
|
kristw
reviewed
Mar 9, 2020
| function ForceDirected(element, props) { | ||
| const { data, width, height, linkLength = 200, charge = -500 } = props; | ||
|
|
||
| let w = window.innerWidth; |
Collaborator
There was a problem hiding this comment.
The chart does not always have width and height being 100% of the window width and height.
Author
There was a problem hiding this comment.
Thanks for the input. I commited a version where width/height are inherited.
kristw
reviewed
Apr 15, 2020
| .attr('width', width) | ||
| .attr('height', height); | ||
| function resize() { | ||
| const { innerWidth, innerHeight } = window; |
Collaborator
There was a problem hiding this comment.
Using window 's innerWidth and innerHeight makes the chart expand beyond its supposed size.
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
💔 Breaking Changes
🏆 Enhancements
📜 Documentation
🐛 Bug Fix
Fix apache/superset#7246
Force directed graph can now be zoomed in/out and panned.
🏠 Internal