-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
DuotonePicker: Simplify Button styles #66641
Conversation
Size Change: -20 B (0%) Total Size: 1.82 MB
ℹ️ View Unchanged
|
e3a8cab
to
f3b7757
Compare
// Used to simulate styles as a .button.has-icon (which this component can't | ||
// opt into, because it has to show more than a simple SVG as the "icon") |
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 is untrue, because the icon
prop renders into an Icon
component internally, which does support arbitrary components.
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.
To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
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.
Looking good, thanks 🚀
* DuotonePicker: Simplify Button styles * Add changelog Co-authored-by: mirka <[email protected]> Co-authored-by: tyxla <[email protected]>
In preparation for #65751
What?
Simplifies the Button styles in DuotonePicker, so there are fewer overrides and matches the Figma specs better.
How?
Moves the button content (swatch and text) from
children
to the designated props on Button (<Button icon={} text={} />
).Testing Instructions
See the Storybook for DuotonePicker.
Screenshots or screencast
The button heights are updated. The spacing between the swatch (
icon
slot) and text is now aligned with the standard spacings.