-
Notifications
You must be signed in to change notification settings - Fork 14.6k
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
[SIP-5] Refactor treemap #5670
[SIP-5] Refactor treemap #5670
Conversation
Codecov Report
@@ Coverage Diff @@
## master #5670 +/- ##
==========================================
- Coverage 63.43% 63.38% -0.05%
==========================================
Files 361 361
Lines 22977 22995 +18
Branches 2558 2559 +1
==========================================
Hits 14575 14575
- Misses 8387 8405 +18
Partials 15 15
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me! Hadn't seen that case for recursive prop checking before 👍
const formatNumber = d3.format(numberFormat); | ||
|
||
function draw(data, eltWidth, eltHeight) { | ||
const margin = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we pass this in as a prop? maybe in the future / not saying it should be part of this PR, just seems weird to include it, with all 0s, and not have it be set-able.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added prop margin
.
* refactor treemap * refactor treemap code * Add proptypes * add proptypes for tree * Add margin prop (cherry picked from commit 54ae215)
* refactor treemap * refactor treemap code * Add proptypes * add proptypes for tree * Add margin prop (cherry picked from commit 54ae215)
* refactor treemap * refactor treemap code * Add proptypes * add proptypes for tree * Add margin prop
* refactor treemap * refactor treemap code * Add proptypes * add proptypes for tree * Add margin prop
Decouple the visualization code from
slice
andformData
Test
Ran a development instance with the code above and verified with production instance that they produce the same results.
@williaster @conglei @graceguo-supercat