Registry Mirror
Skip to content

Conversation

@Dananz

@Dananz Dananz commented Dec 3, 2026

Copy link
Copy Markdown
Contributor

Summary

Pull request Markdown editors lay out Hebrew and Arabic prose left to right. In a draft that starts with an English word, the opening word and ending punctuation can land on the wrong sides.

Apply the existing Markdown prose direction detector in the shared pull request textarea. Comments, review summaries, inline conversations, and descriptions now follow the prose as it changes. Code and URLs do not count toward the direction, and the draft text is preserved. This extracts the Markdown editor direction fix from #27019.

Evidence

In the running T3 Code development app in Chromium, I typed mixed Hebrew and English drafts and a mixed Arabic and English review. The screenshots show the same unsent drafts before and after.

Editor Before After
Comment Mixed Hebrew comment starts on the left Mixed Hebrew comment reads from the right
Review summary Mixed Arabic review starts on the left Mixed Arabic review reads from the right
Inline reply Mixed Hebrew reply starts on the left Mixed Hebrew reply reads from the right
Description Mixed Hebrew description starts on the left Mixed Hebrew description reads from the right

The draft-direction regression failed on the base and passed with the fix. It checks that the editor changes direction as the prose changes and switches back to LTR when Hebrew appears only in inline code. All 37 focused browser tests passed, along with the scoped format, lint, typecheck, Knip, and React Compiler checks.

Merge risk

Revertible change to presentation in one shared textarea.

Built with GPT-6.2 Sol through Codex in T3 Code.

@github-actions github-actions Bot added vouch:unvouched Author is not yet trusted in the VOUCHED list. size:XS 0-9 changed lines (additions + deletions). labels Dec 3, 2026
@macroscopeapp

macroscopeapp Bot commented Dec 3, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Needs Human Approval

Macroscope's review found this PR requires human approval — Pull request editors now automatically derive text direction from Markdown prose. Human review is required to confirm this change to the editor’s default presentation.

You can add or adjust custom eligibility rules. Learn more.

@coderabbitai

coderabbitai Bot commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

Run configuration

Commits

Reviewing files that changed from the base of the PR and between a8464e6 and 11959a8.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
Walkthrough

The Markdown textarea now derives its direction from the prose in its value. A browser test checks left-to-right direction for English, right-to-left direction for Hebrew prose, and left-to-right direction when Hebrew appears only inside inline code.

Changes: Markdown textarea direction

Layer / File(s) Summary
Derive and test textarea direction
apps/web/src/components/pullRequest/PullRequestMarkdownTextarea.tsx, apps/web/src/components/pullRequest/PullRequestMarkdownEditor.browser.test.tsx
The textarea sets its direction with markdownProseDirection(value). The browser test checks direction changes for English, Hebrew prose, and Hebrew text inside inline code.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Suggested reviewers: saphid

Merge Risk: Minimal · previous review a8464

The pull request editor textarea now follows the direction of the prose being typed, ignoring code and URLs. This is a small presentation change with no data or behavior risk identified, so it is ready to merge.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title follows the conventional commit format and names the main change: the pull request editors now follow prose direction. It matches the changeset, which applies the existing Markdown prose dir…
Description check Passed The description covers the problem (Hebrew and Arabic prose laid out left to right in mixed drafts starting with English), the change (applying the existing prose direction detector to the shared pull…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title follows the conventional commit format and names the main change: the pull request editors now follow prose direction. It matches the changeset, which applies the existing Markdown prose direction detector to the shared pull request textarea so the textarea dir follows the prose. The title is specific and does not rely on vague terms.

Full details: Description check

Explanation

The description covers the problem (Hebrew and Arabic prose laid out left to right in mixed drafts starting with English), the change (applying the existing prose direction detector to the shared pull request textarea, excluding code and URLs), and the scope (it extracts the Markdown editor direction fix from #27019). It includes verification details: a regression test that failed on base and passed with the fix, 37 focused browser tests, and before/after screenshots in a table. Gaps against the template: the Scope section does not link a specific bug issue or explain why no issue is needed, so the reviewer cannot confirm it is a bug fix rather than a feature. The Verification section also does not clearly state anything that could not be checked. The description is mostly complete, so the check passes, but the missing issue link should be added.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Additional comments: 1

apps/web/src/components/pullRequest/PullRequestMarkdownEditor.browser.test.tsx-115-116: 1

115-116: Trivial · Maintainability & Code Quality · Quick win

Unverified finding
Verification ran but could not confirm this finding. It is shown for review, not as a verified issue.

Wait for the browser assertions.

Wrap the DOM assertions in vi.waitFor so they follow the browser-test waiting pattern. As per coding guidelines and path instructions, browser tests must assert through expect.element or vi.waitFor.

Also applies to: 120-121

Sources: Coding guidelines, Path instructions

Review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 9a08ffb and a8464e6.

Files selected for processing: 2

  • apps/web/src/components/pullRequest/PullRequestMarkdownEditor.browser.test.tsx
  • apps/web/src/components/pullRequest/PullRequestMarkdownTextarea.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.

@juliusmarminge juliusmarminge added the takeover:in-progress A takeover lead is working on this PR label Dec 3, 2026
@juliusmarminge

Copy link
Copy Markdown
Member

Evidence

Scenario: Pull request markdown editors follow prose direction

Proven: the scenario fails on base 068ec692ae and passes on head 11959a84cc.

Base 068ec692ae Head 11959a84cc
Result ❌ failed
ASSERTION_FAILED: expect.poll(...).toBe(...) timed out after 15000 ms
last: expected "ltr" to be "rtl"
✅ passed
failure Base 068ec692ae: failure
rtl comment editor Head 11959a84cc: rtl comment editor
rtl review editor Head 11959a84cc: rtl review editor

Scenario driver: rtl-pr-editors.e2e.ts

@juliusmarminge juliusmarminge added takeover:ready Takeover done; auto-lands when gates pass and removed takeover:in-progress A takeover lead is working on this PR labels Dec 3, 2026
@juliusmarminge
juliusmarminge merged commit ab07a09 into pingdotgg:main Dec 3, 2026
57 checks passed
@juliusmarminge juliusmarminge removed the takeover:ready Takeover done; auto-lands when gates pass label Dec 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XS 0-9 changed lines (additions + deletions). vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants