-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Global Styles: Add back the global styles logic that forces the solid border when color or width applied. #50498
Conversation
settings={ settings } | ||
/> | ||
) } | ||
{ hasEffectsPanel && ( | ||
<StylesEffectsPanel | ||
inheritedValue={ inheritedStyleWithLayout } | ||
value={ styleWithLayout } | ||
onChange={ onChangeDimensions } | ||
onChange={ setStyle } |
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 an unrelated change but it's a small optim/typo fix (same for the next change)
Size Change: +198 B (0%) Total Size: 1.39 MB
ℹ️ View Unchanged
|
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.
Thanks for the quick fix @youknowriad 🚀
It looks like we'll need another small tweak to match the current code in the global styles border panel.
Also, can we now remove the global styles border panel entirely?
I'm out of time today but will give this a full test tomorrow and can make any further updates needed then if you'd like.
Flaky tests detected in 6c0944bda921fb8ab9f67f759a36d2d2ece9910b. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/4935178260
|
Updated. Indeed, the border panel seems like dead code 👍 |
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.
LGTM 🚢
✅ Border controls work as expected in both block editor and global styles
✅ Code changes look good including old global styles border panel removal
✅ Border radius is maintained when adjusting other global styles border properties
The failing unit tests look related to the Fonts API that I believe was reverted overnight. I'll rebase the PR and see if we can't get them passing.
Thanks again for the quick work on this.
… border when color or width applied.
6c0944b
to
0f5a1c4
Compare
Fixes a regression introduced int #49428
See #49428 (comment)
What?
In Global Styles, we have some logic in place that forces the border style to be "solid" when a color/width is applied. This PR just restores that logic that was removed inadvertently.
Testing Instructions
1- Open the "button" global styles panel
2- Type 1px in the "border width" input
3- Verify that the "solid" style is applied on the button