Skip to content

Fix RTL layout on Connectors admin screen#11247

Closed
tejas0306 wants to merge 2 commits intoWordPress:trunkfrom
tejas0306:fix-64857-rtl-connectors
Closed

Fix RTL layout on Connectors admin screen#11247
tejas0306 wants to merge 2 commits intoWordPress:trunkfrom
tejas0306:fix-64857-rtl-connectors

Conversation

@tejas0306
Copy link
Copy Markdown

Addresses two RTL issues on Settings → Connectors when the admin locale is RTL (e.g. Arabic, Hebrew, Central Kurdish):

• Page heading alignment
The "Connectors" heading remained left-aligned in RTL. The page header used justify-content: left, which does not respect document direction. This patch adds an RTL override so the heading aligns to the inline-start edge (right in RTL).

• Admin menu current-item arrow
The Connectors page injected border-right-color: #fff for the current menu item arrow, which is correct in LTR. In RTL, WordPress uses border-left-color, causing a duplicate arrow to appear. This patch removes the right border color and applies border-left-color: #fff for RTL so only the correct arrow is displayed.

Additionally sets $submenu_file = 'options-connectors.php' so the Settings → Connectors menu item highlights correctly.

Fixes https://core.trac.wordpress.org/ticket/64857

@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 13, 2026

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 props-bot label.

Core Committers: Use this line as a base for the props when committing in SVN:

Props suhan2411, mukesh27.

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@github-actions
Copy link
Copy Markdown

Test using WordPress Playground

The changes in this pull request can previewed and tested using a WordPress Playground instance.

WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser.

Some things to be aware of

  • All changes will be lost when closing a tab with a Playground instance.
  • All changes will be lost when refreshing the page.
  • A fresh instance is created each time the link below is clicked.
  • Every time this pull request is updated, a new ZIP file containing all changes is created. If changes are not reflected in the Playground instance,
    it's possible that the most recent build failed, or has not completed. Check the list of workflow runs to be sure.

For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation.

Test this pull request with WordPress Playground.

Copy link
Copy Markdown
Member

@mukeshpanchal27 mukeshpanchal27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!

The approach not make sense to me. Instead for adding additional action and inline script we have to check how to fix the issue with that inline style on connector option page.

// Set parent file for menu highlighting.
$parent_file = 'options-general.php';
$parent_file = 'options-general.php';
$submenu_file = 'options-connectors.php';
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
$submenu_file = 'options-connectors.php';

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mukeshpanchal27 Thanks for the review.

I’ve removed the extra admin_head action and the inline script so the patch no longer adds additional actions or inline styles.

The remaining fix focuses only on the RTL menu arrow issue on the Connectors screen.

Please let me know if you’d prefer a different approach.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mukeshpanchal27 I’d recommend keeping this line.

$submenu_file is the standard way in wp-admin to mark the active submenu item. Without it, the "Connectors" item under Settings is not highlighted when visiting the page.

This follows the same pattern used in other options pages such as options-general.php.

@mukeshpanchal27
Copy link
Copy Markdown
Member

@tejas0306 Check https://core.trac.wordpress.org/ticket/64857#comment:7, @jorgefilipecosta open PR WordPress/gutenberg#76496 that fix the issue.

Closing in favour of GB PR

@tejas0306 tejas0306 deleted the fix-64857-rtl-connectors branch March 14, 2026 06:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants