-
Notifications
You must be signed in to change notification settings - Fork 4.4k
TextControl: Fix text direction for URL and email fields in block editor for RTL languages #68561
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
TextControl: Fix text direction for URL and email fields in block editor for RTL languages #68561
Conversation
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. |
2e0bb79
to
2780c08
Compare
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! It also works correctly on Storybook.
711a1ab24323df5ab5c4b57c76706306.mp4
Can you resolve the code conflict? Please resolve the conflict so that an entry for this PR is added to the Unreleased > Bug Fixes section.
615b1ba
to
f3ef531
Compare
Hi @t-hamano , Updated the PR with the suggested changes. Please have a look when you have a moment. |
…tor for RTL languages (WordPress#68561) * fix: add ltr for email and url in the textcontrol component * doc: Add changelog * doc: Add changelog in unreleased section * doc: Update changelog Co-authored-by: im3dabasia <im3dabasia1@git.wordpress.org> Co-authored-by: t-hamano <wildworks@git.wordpress.org>
Fixes TextControl Component Part of this issue.
Related issues: #65893
Related comment: #68188 (review)
What?
Adds direction: ltr for URL and email input fields in the block editor to ensure correct text alignment, especially for RTL languages.
Why?
Currently, in RTL languages, the block editor shows URL and email fields from right to left, which is not ideal. As suggested in the issue, these fields should be displayed left to right (LTR) regardless of the language direction for consistency and better usability.
How?
Added the below CSS
Screenshots
Before
Screen.Recording.2025-01-30.at.5.39.03.PM.mov
After
Screen.Recording.2025-01-30.at.5.37.30.PM.mov