-
Notifications
You must be signed in to change notification settings - Fork 382
Closed
Labels
AccessibilityChanges that impact accessibility and need corresponding review (e.g. markup changes).Changes that impact accessibility and need corresponding review (e.g. markup changes).BugSomething isn't workingSomething isn't workingi18n
Milestone
Description
Bug Description
The Stories editor is currently not usable at all when using an RTL language. Even with the changes in #2977 applied.
It's mostly arrow icons that are not flipped, and the transform in the EditorCarousel component that doesn't change when isRTL.
Expected Behaviour
The stories editor should work just fine in RTL mode.
Steps to reproduce
- Install RTL Tester plugin and click on "Switch to RTL" in the admin bar. Or, alternatively, switch user language to an RTL language like Arabic.
- Open stories editor
- Notice how not all of the layout elements are "flipped" and the editor is not usable
- Notice that the context menu doesn't seem to be working either.
Screenshots
Additional context
- WordPress version: 5.3
- Plugin version: current
develop - Gutenberg plugin version (if applicable): 6.6
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
- The current page in the carousel should be correctly centered and navigation should be possible the same way as in LTR mode
- Iconography should be adapted (flipped) accordingly in the context menu as well as the carousel navigation
[ ] It should be possible to access the context menu as expected-> see Context menu not accessible in RTL mode #3607- Dragging between pages should work as expected and highlight the correct target pages
- Resize handles should be displayed the same way as in LTR mode
Implementation brief
- Wherever code changes are needed,
select( 'core/block-editor' ).getSettings().isRTLis used to switch the logic for RTL mode. - If necessary, CSS changes are made to improve RTL compatibility.
- Add
rtl:ignorecomments for resize handles
QA testing instructions
Setup before any test below
- Activate RTL Tester plugin
- Click on "Switch to RTL" in the admin toolbar at the top
- Create a new story
Verify carousel
- Create few pages and go through the carousel
- Verify: the currently selected page should always be shown in the center
- Verify: carousel arrows should point into the right direction and navigate correctly
- Verify: dragging pages in carousel works as intended
Verify resize handles
- Edit text block
- Verify: the resize handles should be displayed at every location correctly
Verify dragging across pages
- Drag block to another page
- Verify: the correct page is highlighted when hovering over it
- Verify: the correct placement when dropped on another place
Verify CTA block layout
- Add CTA block on a new page
- Click on button to edit the URL
- Verify: the URL input field should not overlap the button
Demo
Changelog entry
- Improved RTL support in the editor
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
AccessibilityChanges that impact accessibility and need corresponding review (e.g. markup changes).Changes that impact accessibility and need corresponding review (e.g. markup changes).BugSomething isn't workingSomething isn't workingi18n
