Skip to content

i18n(he): translate the text direction to rtl - #690

Merged
Randy808 merged 1 commit into
Blockstream:masterfrom
DeviaVir:fix-hebrew-rtl-direction
Oct 7, 2026
Merged

Randy808 merged 1 commit into
Blockstream:masterfrom
DeviaVir:fix-hebrew-rtl-direction

Conversation

@DeviaVir

@DeviaVir DeviaVir commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

lang/he.po has an empty msgstr for ltr, so t`ltr` stays ltr in Hebrew. <body dir> (set in client/index.pug and by the language switch in client/src/app.js) is therefore left-to-right.

The RTL stylesheet already lays the page out right-to-left, so the page looks the same. The dir attribute is still what screen readers, the bidi ordering of mixed Hebrew/Latin text (addresses, txids) and form inputs rely on.

  • lang/he.po: msgid "ltr" → msgstr "rtl".
  • lang/he.json: adds only "ltr": "rtl". The file is not regenerated, because po2json would undo the hand-fixed "in %s blocks (%s from tip)" string.

Checked in a local build with headless Chromium: switching to Hebrew sets dir="rtl" (computed rtl) and loads style-rtl; English and German stay ltr; no page errors. Unit tests pass.

Note: the translation should also be set in Transifex, otherwise the next l10n:fetch resets it.

lang/he.po had an empty msgstr for "ltr", so t`ltr` stayed "ltr" in
Hebrew and <body dir> (index.pug, and the language switch in app.js) was
left-to-right. The RTL stylesheet already lays the page out right-to-left;
this fixes the dir attribute that screen readers, bidi ordering of mixed
Hebrew/Latin text (addresses, txids) and form inputs rely on.

he.json gets only the new key; it is not regenerated, so the hand-fixed
"in %s blocks (%s from tip)" string stays as it is.
@DeviaVir
DeviaVir requested review from Randy808 and a balanced review from Copilot October 7, 2026 07:28
@DeviaVir
DeviaVir marked this pull request as ready for review October 7, 2026 07:28

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot review overview

🟢 Approval recommended

The PO and JSON updates are consistent with the existing Hebrew RTL stylesheet configuration.

Review effort: Balanced
Findings: None

What changed in this PR

Sets Hebrew text direction to RTL for accessibility and bidirectional text handling.

Changes:

  • Translates the ltr direction marker to rtl.
  • Synchronizes the PO and runtime JSON translations.
File Description
lang/​he.po Defines Hebrew text direction as RTL.
lang/​he.json Adds the runtime RTL direction mapping.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@Randy808
Randy808 merged commit cfcb22c into Blockstream:master Oct 7, 2026
3 checks passed
@DeviaVir
DeviaVir deleted the fix-hebrew-rtl-direction branch October 7, 2026 13:06
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.

3 participants