Skip to content

Force LTR for ability schema JSON viewer#485

Merged
dkotter merged 1 commit into
WordPress:developfrom
t-hamano:rtl-force-json-ltr
Apr 29, 2026
Merged

Force LTR for ability schema JSON viewer#485
dkotter merged 1 commit into
WordPress:developfrom
t-hamano:rtl-force-json-ltr

Conversation

@t-hamano
Copy link
Copy Markdown
Contributor

@t-hamano t-hamano commented Apr 29, 2026

Part of #483

What?

Force LTR direction on the ability schema JSON viewer in the Abilities Explorer.

Why?

JSON output is structurally LTR and should not be flipped when the admin language is RTL.

How?

Add direction: ltr; to .ability-schema-display with an /*rtl:ignore*/ directive so RTLCSS preserves it in the generated -rtl.css.

Use of AI Tools

AI assistance: Yes
Tool(s): Claude Code
Model(s): Claude Opus 4.7
Used for: Diagnosing the malformed rtl:ignore comment and applying the fix.

Testing Instructions

  1. Switch the WP admin to an RTL language (e.g. Arabic).
  2. Open Abilities Explorer and view an ability's schema.
  3. Confirm the JSON renders left-to-right.
Before After
image image

Changelog Entry

Fixed - Ability schema JSON viewer now stays LTR under RTL admin languages.

Open WordPress Playground Preview
JSON output should always render left-to-right regardless of the
admin language. Adds rtl:ignore so RTLCSS preserves the LTR
direction in the generated -rtl.css.
@t-hamano t-hamano marked this pull request as ready for review April 29, 2026 04:12
@github-actions
Copy link
Copy Markdown

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.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: t-hamano <wildworks@git.wordpress.org>

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

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 29, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 69.06%. Comparing base (a44e792) to head (554db2d).
⚠️ Report is 3 commits behind head on develop.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop     #485   +/-   ##
==========================================
  Coverage      69.06%   69.06%           
  Complexity       957      957           
==========================================
  Files             60       60           
  Lines           4512     4512           
==========================================
  Hits            3116     3116           
  Misses          1396     1396           
Flag Coverage Δ
unit 69.06% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
@gziolo gziolo added the [Type] Bug Something isn't working label Apr 29, 2026
@dkotter dkotter added this to the 0.9.0 milestone Apr 29, 2026
@dkotter dkotter merged commit c9dfaa6 into WordPress:develop Apr 29, 2026
22 of 34 checks passed
@t-hamano t-hamano deleted the rtl-force-json-ltr branch April 29, 2026 16:49
@jeffpaul jeffpaul linked an issue May 7, 2026 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Type] Bug Something isn't working

4 participants