-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Button Block: Change text-decoration style to low specificity #42545
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
Conversation
dce1c36 to
d7fe6f7
Compare
|
Size Change: -6 B (0%) Total Size: 1.26 MB
ℹ️ View Unchanged
|
|
Not a blocker: I'm not sure sure about the change requested to the theme as this a default style part of the theme design. Changing the underline should be a choice, I mean that changing the block or global style setting should override the default style? |
carolinan
left a comment
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 have confirmed that the underline displays on the front.
Fix #42292
What?
This PR reduces the specificity of
text-decorationstyle given to.wp-block-button__linkin the front end style ofcore/button.Why?
Text decoration styles may be defined in
theme.json.In addition, if
textDecorationis specified instyles.elements.button,.wp-block-button__linkis also subjected to it.However, the settings in
theme.jsonare not reflected becausetext-decoration:noneis defined as the default button style.How?
I have reduced the specificity of the default style of the buttons, referring to #41393.
Testing Instructions
text-decorationis none as before.textDecorationto "underline" for the button element:{ "styles": { "elements": { "button": { "typography": { "textDecoration": "underline" } } } } }Screenshots or screencast
Point of Concern
In Twenty Twenty Two, if
textDecoration: "underline"is applied to a button element, it changes to dashed style on hover or focus.However, I think this is an issue that should be addressed on the theme side.