-
Notifications
You must be signed in to change notification settings - Fork 841
Forms: Fix checkbox styling with filter invert and correct border color #46150
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
base: trunk
Are you sure you want to change the base?
Conversation
|
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
|
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 Follow this PR Review Process:
If you have questions about anything, reach out in #jetpack-developers for guidance! Jetpack plugin: The Jetpack plugin has different release cadences depending on the platform:
If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack. |
Code Coverage SummaryThis PR did not change code coverage! That could be good or bad, depending on the situation. Everything covered before, and still is? Great! Nothing was covered before? Not so great. 🤷 Full summary · PHP report · JS report Coverage check overridden by
Coverage tests to be added later
|
|
It would be good to include screenshots with these PRs @CGastrell so that it is easier to compare the different implementations. This PR: The second checkbox in this screenshot is selected checkbox. I think this PR is getting things pretty close but is somehow still missing something. I was expecting the border to stay the same as trunk. Maybe we need to tweak a few more things here to make it look more like expected? ( it should look like the current trunk implementation) |
I'm testing on ~20 themes, pasting before/after seems a bit like not gonna cover all the cases, so everyone can test their own case |
Do we actually know current trunk is the expected output? We keep talking about what's "expected", but seems to me that's just how it looks now on trunk, not necessarily the actual expectation. Besides, these 2 PRs aim for fixing a bug while achieving some consistency. Also on the topic of "expected", most themes not even have a case for inputs, so I'm not sure there's always an expectation (some do). In a way, we're just paving what the default look should be on our inputs, trying to be consistent and retain readability. cc @ilonagl @ederrengifo do we have designs on themes and how those should render inputs/checkboxes? That would help a lot. |
58f99be to
cf018e5
Compare


This is an alternative to #46129 getting to the same "contrast" goal but with an inverted approach.
Proposed changes:
background-color: currentColorwithfilter: invert(1)for checked checkbox state--jetpack--contact-form--text-colorvariable for border color instead of--jetpack--contact-form--inverted-text-colorThese changes fix checkbox styling issues where checkboxes appeared unclickable with white text on dark backgrounds, and ensure the checkbox color settings apply correctly to both the text and checkbox box.
Other information:
Jetpack product discussion
Related to checkbox styling improvements and color consistency issues reported by users.
Does this pull request change what data or activity we track or use?
No, this is purely a CSS styling fix.
Testing instructions:
Before / After
Before: Checkboxes used
background-color: currentColorwhich didn't provide proper styling and the border used an inverted text color variable.After: Checkboxes use
filter: invert(1)for the checked state and the border uses the correct text color variable, providing consistent and accessible checkbox styling.