-
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
Fix/issue#59698 #59719
base: trunk
Are you sure you want to change the base?
Fix/issue#59698 #59719
Conversation
adding logic to check if a prefix or suffix exists. Then adding the appropriate wrappers to the result
I noticed how the input control component this is based on was handling it's type sizes. That seemed like a cleaner place to make the change, rather than in the selectControl component where it seems like it needed to be over-ridden with a media query.
Warning: Type of PR label mismatch To merge this PR, it requires exactly 1 label indicating the type of PR. Other labels are optional and not being checked here.
Read more about Type labels in Gutenberg. Don't worry if you don't have the required permissions to add labels; the PR reviewer should be able to help with the task. |
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. |
👋 Thanks for your first Pull Request and for helping build the future of Gutenberg and WordPress, @dabowman! In case you missed it, we'd love to have you join us in our Slack community. If you want to learn more about WordPress development in general, check out the Core Handbook full of helpful information. |
Currently discussing the best approach in #59698. |
What?
Adjusting the styling of the selectControl component and the inputControl component to account for situations where prefixes and suffixes are used. Also adding responsive type sizes to prefixes and suffixes.
Why?
This is to address issue #59698
How?
I added the provided wrapper components for prefixes and suffixes to the selectControl component to resolve the padding issue.
I added the responsive type styles to the prefix and suffix in the base inputControl component. Much of the styling of the selectControl seems to have been copy/pasted from inputControl but the prefix and suffix are using the base components styles. I added the responsiveness there to resolve it wherever it appears.
Testing Instructions
Open the selectControl and inputControl components in storybook.
Add prefix and suffix values
In selectControl, See that there is padding added to the left and right and in both selectControl and inputControl see that the type size is using the same responsive styles as the placeholder and value text.