Skip to content

Add RTL/bidi language support for Inky (fixes #122)#1

Merged
VRDate merged 1 commit intomasterfrom
claude/fix-inky-122-tJ7An
Feb 27, 2026
Merged

Add RTL/bidi language support for Inky (fixes #122)#1
VRDate merged 1 commit intomasterfrom
claude/fix-inky-122-tJ7An

Conversation

@VRDate
Copy link
Owner

@VRDate VRDate commented Feb 27, 2026

Implement Unicode bidi preprocessing for Right-to-Left languages (Hebrew, Arabic, Persian, etc.) via a single-file bidify.js module that injects directional isolate markers (LRI/RLI/PDI).

Integration points:

  • playerView.js: bidify() on story text before DOM
  • inkFile.js: stripBidi() before saving to disk
  • inklecate.js: bidifyJson() for compiled ink JSON export
  • appmenus.js: View > Bidify (RTL) submenu with 4 toggles
  • export-for-web: direction:rtl global tag support

Test infrastructure:

  • 29 unit tests (bidify.js pure functions, 10 RTL scripts)
  • 7 app E2E tests via Playwright/Spectron launcher abstraction
  • 15 bidi E2E tests (Hebrew/Arabic typing, compile, playthrough)
  • Spectron compatibility patches for Electron 30 + Node 22

Documentation:

  • Architecture, sequence, data-flow, and test PUMLs
  • BIDIFIER_ARCHITECTURE.md
  • UI layout, menus, and workflow diagrams

Implement Unicode bidi preprocessing for Right-to-Left languages
(Hebrew, Arabic, Persian, etc.) via a single-file bidify.js module
that injects directional isolate markers (LRI/RLI/PDI).

Integration points:
- playerView.js: bidify() on story text before DOM
- inkFile.js: stripBidi() before saving to disk
- inklecate.js: bidifyJson() for compiled ink JSON export
- appmenus.js: View > Bidify (RTL) submenu with 4 toggles
- export-for-web: direction:rtl global tag support

Test infrastructure:
- 29 unit tests (bidify.js pure functions, 10 RTL scripts)
- 7 app E2E tests via Playwright/Spectron launcher abstraction
- 15 bidi E2E tests (Hebrew/Arabic typing, compile, playthrough)
- Spectron compatibility patches for Electron 30 + Node 22

Documentation:
- Architecture, sequence, data-flow, and test PUMLs
- BIDIFIER_ARCHITECTURE.md
- UI layout, menus, and workflow diagrams
@VRDate VRDate merged commit 8c7782c into master Feb 27, 2026
VRDate pushed a commit that referenced this pull request Feb 27, 2026
Resolved conflicts from app/ → ink-electron/ rename:
- package.json: merged test scripts (playwright launcher + incremental)
- playerView.js: added setDirection export
- docs/bidi/: accepted master's authoritative docs
- app/test/test.js: removed (already in ink-electron/test/)
- package-lock.json: accepted master's with spectron

https://claude.ai/code/session_017wQBE8vrQVTgjg7rWgtYP6
@VRDate VRDate deleted the claude/fix-inky-122-tJ7An branch March 3, 2026 11:35
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