Skip to content
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

Add support for margin to ordinal color legend. #1082

Conversation

dgwyer
Copy link

@dgwyer dgwyer commented Oct 11, 2022

src/legends/swatches.js Outdated Show resolved Hide resolved
Comment on lines 183 to 184
? `margin-bottom: 0.5em;`
: `margin-bottom: ${+marginBottom}px;`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this mix seems like a problem, not sure how to unify that properly. Should we default to the equivalent number of pixels, on line 93?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've updated it to default to 8px which should be the equivalent. What do you think?

@dgwyer
Copy link
Author

dgwyer commented Oct 14, 2022

Not sure what went on with the previous commit (32e26ed) but hopefully it's ok now.

@Fil
Copy link
Contributor

Fil commented Oct 16, 2022

For me it seems like 5px instead of 8px would make it visually unchanged in the unit tests.

@Fil
Copy link
Contributor

Fil commented Oct 17, 2022

I'm sorry I went back to the original idea, in order to minimize churn. Please add your review (or thumbs up or down) on #1090. Thank you for the contribution!

@Fil Fil closed this Oct 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants