-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
Remove Gutenberg form control resets and include the styles in the components #22596
Conversation
Size Change: -19.7 kB (1%) Total Size: 1.1 MB
ℹ️ View Unchanged
|
@ItsJonQ @jasmussen any thoughts here? |
I have been rekt by this so many times! .input-control, // Upstream name is `.regular-text`.
input[type="text"],
input[type="search"],
input[type="radio"],
input[type="tel"],
input[type="time"],
input[type="url"],
input[type="week"],
input[type="password"],
input[type="checkbox"],
input[type="color"],
input[type="date"],
input[type="datetime"],
input[type="datetime-local"],
input[type="email"],
input[type="month"],
input[type="number"],
select, This is a wonderful update @youknowriad Any suggestions for a good way to test for regressions? (Perhaps specific things to look for?) Thanks! |
From what I can tell, and in my careful testing, I can see only upsides and no downsides to this. I'm testing in an opinionated theme with a crazy editor style and things work well. But I do want to echo Q's thought: is there anything in particular to look for? |
Basically, the idea is to check how inputs, checkboxes, radio buttons look across the UI. |
Yep, so far that's what I tested and it worked well for me. I'm happy to approve, depending on how much testing you feel this needs. |
Please do approve, I'll continue my own testing too and merge. |
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 important work, not just for code quality but for componentization. Thanks Riad. Let's get this in and catch any regressions before the next release.
Let's try this. |
During the weekend, I played a little bit with Gutenberg packages outside WordPress and of the struggles I had is that most form control components relies on some kind of assumed styles that come from WordPress Core (or Gutenberg reset mixin).
This PR tries to embed these styles in the components them selves making them more reusable. It also removes the global reset for inputs, checkboxes... so it's one of those PRs where we'll be on a better position code quality wise but we need to be very careful with testing before merging.