Skip to content

fix(web): keep the start and ellipsis of cut titles in Firefox and Safari in right-to-left languages - #4853

Merged
Quick104 merged 6 commits into
mainfrom
fix/rtl-truncated-title-ellipsis
Nov 21, 2026
Merged

Quick104 merged 6 commits into
mainfrom
fix/rtl-truncated-title-ellipsis

Conversation

@Quick104

@Quick104 Quick104 commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Related issue: N/A
Validation tasks: none

Other clients: Apple N/A, Android N/A, Roku N/A (a browser layout fix: where Firefox and Safari draw a CSS ellipsis)

In a right-to-left interface such as Arabic, Firefox and Safari cut long English titles on the wrong side. In a 160 px card, Firefox shows "The Lord of the Rings: Th" with no "…", and Safari shows "…e Lord of the Rings: Th", cutting both the first letters and the end. Cast names and roles, episode titles, audiobook authors and clamped overviews have the same problem. In the English interface, Safari also cuts the first letter off an Arabic title. Chromium already shows all of these correctly. With this change, Firefox and Safari also keep the start of the text and end it with "…".

These elements use .bidi-text. Its unicode-bidi: plaintext gives the text its own direction but leaves the element's direction at the page's. Firefox and WebKit cut the text and draw the "…" at the end of the element's direction, so text that runs the other way gets cut on the wrong side.

Approach

Every .bidi-text element that is cut with an ellipsis now also has dir="auto", so the element takes its direction from its first letter. The elements are:

  • the poster card title shared by library, home, request, box set and watchlist cards
  • episode titles and audiobook authors on cards
  • cast names and roles
  • the home hero overview, the episode card overview and the detail overview
  • the detail page title, which detailLayout.css clamps

.bidi-text stays. Its text-align: match-parent keeps a short title on the page's start side, and the title links keep their full width. The rule is written in the comment above .bidi-text and in web/src/i18n/README.md, next to the username rule from #4783, whose note about .bidi-text now says it needs dir="auto".

Chromium still shows no "…" on clamped text that is aligned to the end of its own direction, such as an English overview or detail page title in Arabic. That happens before and after this change. Fixing it would change these same elements, so it is tracked in #4858, to fix after this merges.

Some cut titles don't use .bidi-text at all: the Continue Watching heading, the episode list's "S01E02 · title" line and collection cards. They lose their start in every engine and will be fixed in a separate pull request.

Validation

  • Reproduced before the change and checked after it in Chromium 153, Firefox 155 and WebKit 26.6 through Playwright. The check used a temporary dev-only page, not part of this change, that renders the real card, cast, overview and title components with sample data, in the Arabic and English interfaces, at phone, tablet and desktop widths. A sandbox server couldn't start, so the change wasn't checked against a running server with a real library.
  • After the change, in all three engines: the detail overview's More and Less buttons work, keyboard focus and clicks reach the card title link, and the link keeps its width.
  • Typecheck, ESLint and Prettier pass on the changed files, and so do the web tests that render these components.

Evidence: https://evidence.siloserver.org/r/silo-server/pr-4853/

Risks

The change only sets dir="auto" on elements that hold nothing but text, and the [dir="rtl"] rules in app.css don't match auto.

One known limit: a collection description keeps its line breaks, and dir="auto" takes its direction from the first paragraph. When a later paragraph runs the other way and gets clamped, such as an English first line over an Arabic body in the Arabic interface, Firefox cuts the start of its last line and WebKit drops its "…". An all-English or all-Arabic description, the common case, is fixed. No single direction suits every paragraph of one clamped block. A comment at DetailOverview records this.

Checklist

  • I read and can explain the complete diff.
  • This pull request addresses one concern.
  • Each test this pull request adds meets "Decide what to test" in CONTRIBUTING.md.
  • The Evidence section shows every change a user can see, or how I checked a change nobody sees.

Council review

Background review: 1 round, reviewed 570ad37.

Member Round 1
Sol (gpt-6.2-sol, xhigh) 8/10
Opus (claude-opus-5-5, high) 8/10
Gemini (gemini-4-neon, xhigh) 8/10

Fixed: DetailTitle adds .bidi-text itself, next to dir="auto" (Gemini; dae14ed). The README now says what Firefox and WebKit show without dir="auto" (Gemini; 176af23), and the username rule's note about .bidi-text is corrected (Opus, Gemini, Sol; 044ba6d). Answered: exporting dir with the card title class would trip the Fast Refresh lint rule in that file (Opus). Clamped multi-paragraph collection descriptions are a known limit, listed under Risks (Gemini, Sol). Sol would keep the page's direction for descriptions with line breaks instead; that brings back the original bug for one-language descriptions with paragraphs, so it is left for a maintainer decision.

Visual review: 1 round on the final captures.

Member Round 1
Sol better, 8/10
Opus better, 8/10
Gemini better, 8/10

Answered:

AI Disclosure

  • Harness: Claude Code (in T3 Code)
  • Tool(s): Claude Code; T3 Code delegated tasks for the council (Codex, Claude, Antigravity); Playwright for captures
  • Model(s): claude-opus-5-5 (implementation); gpt-6.2-sol, claude-opus-5-5, gemini-4-neon (council); claude-opus-5-5 and claude-sonnet-5-5 (code-review subagents)
  • Involvement: Fully AI-generated. The agent checked it on a dev-only page that renders the real components. A person has not checked it yet.
  • Adversarial review: a plan round by all three council members. Opus trimmed the docs to one rule in app.css and a short README line, Gemini corrected why Chromium drops the clamped "…", and Sol's and Gemini's report of cut titles without .bidi-text became the follow-up. Code review ran at xhigh with three finders, a sweep and a 1.0 validation check. It reworded the rule to cover stylesheet clamps and added a note at the shared title class. Visual review and background review are under Council review.

🤖 Generated with Claude Code

…fari in right-to-left languages

Metadata text styled with .bidi-text takes its paragraph direction from its
own text, but the element's direction stays the page's. Firefox and WebKit
cut the text and draw the "…" at the end of that direction, so in Arabic a
long English card title lost its "…" in Firefox and its first letters in
Safari, and clamped overviews put the "…" at the start of their last line.

Give every .bidi-text element that is cut with truncate or line-clamp
dir="auto" (card titles, episode titles, audiobook authors, cast names and
roles, the home hero, episode and detail overviews, and the bounded detail
title). .bidi-text still lines the box up with the page, so short titles
stay on the page's start side and links keep their width.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-triage silo-triage Bot added the size/S 0–49 added + deleted lines (all files); change volume, not priority. label Nov 21, 2026
@coderabbitai

coderabbitai Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

  • Ask an admin to enable usage-based reviews

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Next included review available in 2 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 4 included reviews currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 2df95111-1dd3-4a91-b02f-82a8a9d5a80a
Commits

Reviewing files that changed from the base of the PR and between 50cbe1f and 415e06f.

Files selected for processing: 14

  • web/src/app.css
  • web/src/components/CastCarousel.tsx
  • web/src/components/HeroOverviewText.tsx
  • web/src/components/ItemCard.tsx
  • web/src/components/MediaCardArtwork.tsx
  • web/src/components/RequestPosterCard.tsx
  • web/src/components/SectionItemCard.tsx
  • web/src/components/boxsets/BoxSetCard.tsx
  • web/src/components/watchlist/WatchlistTitleCard.tsx
  • web/src/i18n/README.md
  • web/src/pages/ItemDetail/DetailHero.tsx
  • web/src/pages/ItemDetail/DetailTitle.tsx
  • web/src/pages/ItemDetail/components/DetailOverview.tsx
  • web/src/pages/ItemDetail/components/EpisodeCardCaption.tsx
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@silo-kody

silo-kody Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-21T05:35:19.859485Z 415e06f New commits
🔒 Security Review ✅ Completed 2026-11-21T05:37:18.023380Z 415e06f New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Comment thread web/src/i18n/README.md Resolved
@silo-triage silo-triage Bot added bug Something isn't working impact: polish Annoyance, cosmetic, or nice-to-have javascript Pull requests that update javascript code priority: P2 Limited scope, workaround exists, or polish labels Nov 21, 2026
… rule

The username rule from #4783 said not to use .bidi-text because plaintext
drops the "…" in Firefox and cuts the start in WebKit. That holds only for
.bidi-text without dir="auto". Say so, and put the metadata rule next to it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-triage silo-triage Bot added size/M 50–199 added + deleted lines (all files); change volume, not priority. and removed size/S 0–49 added + deleted lines (all files); change volume, not priority. labels Nov 21, 2026
@silo-kody

silo-kody Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌
⚠️ 4 Kody Rule(s) were not evaluated

These rules declare that they need repository context beyond this diff, and the review could not retrieve it, so they were not judged on this pull request:

  • Preserve optional store capabilities through production wrappers
  • Detach mandatory cleanup from request cancellation and bound its lifetime
  • Preserve durable media identity and share identity-evidence precedence
  • Bound decoder throughput trades and share direct-play eligibility

@Quick104 Quick104 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Adversarial review (claude-opus-5-5, reviewed 570ad37)

The fix is right: dir="auto" is the only way to set an element's own direction from its text, and CSS can't do it, so this needs a markup change. I checked every .bidi-text element on this commit. Every one cut with an ellipsis now has dir="auto". The others are HeroBanner h1, the AudiobookContent and EbookContent h1s, the DetailHero tagline and the RestoreChoose name; none of them is truncated or clamped. ViewTransitionLink passes dir through to the anchor.

I found no side effects. The custom rtl: variant and the icon-mirroring rule match only [dir="rtl"] and [dir="ltr"], so dir="auto" doesn't change them. None of the touched elements uses a logical margin or padding, and none contains an icon. text-align: match-parent keeps the page's alignment. The DetailTitle measuring span and the DetailOverview overflow check measure height, which doesn't depend on direction.

Two findings, inline:

  1. The new README bullet contradicts the one #4783 already merged a few lines above it.
  2. Nit: the card-title class now depends on an attribute it can't carry.

Comment thread web/src/i18n/README.md Resolved
// Caption typography shared by poster cards, so a library title and a title
// known only from TMDB read the same under their artwork.
// known only from TMDB read the same under their artwork. A title with
// MEDIA_CARD_TITLE_CLASS also takes dir="auto" (see `.bidi-text` in app.css).

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Nit: fix the boundary, not the comment. MEDIA_CARD_TITLE_CLASS is used only as the bare className of the five card-title links, and now each of them must also add dir="auto". This comment keeps the two in sync by convention only. A sixth card that copies the class without the attribute brings the bug back in Firefox and WebKit, and nothing catches it.

Repair: export the attribute together with the class, for example export const MEDIA_CARD_TITLE_PROPS = { dir: "auto", className: "bidi-text block truncate …" } as const;, and spread it at the five sites (<ViewTransitionLink to={href} {...MEDIA_CARD_TITLE_PROPS}>). Then the comment and the five separate dir="auto" attributes can go.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Not changing this one. Exporting an object from MediaCardArtwork.tsx trips react-refresh/only-export-components, which allows only string and number constants beside a component. Moving the caption constants into their own module would fix that, but it widens this change to every caption import. The comment at the constant names the pairing, and the five call sites all have dir="auto". Leaving the thread open in case you want the module split.

🤖 Claude Code (claude-opus-5-5)

@silo-kody

silo-kody Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌
⚠️ 4 Kody Rule(s) were not evaluated

These rules declare that they need repository context beyond this diff, and the review could not retrieve it, so they were not judged on this pull request:

  • Preserve optional store capabilities through production wrappers
  • Detach mandatory cleanup from request cancellation and bound its lifetime
  • Preserve durable media identity and share identity-evidence precedence
  • Bound decoder throughput trades and share direct-play eligibility

@Quick104 Quick104 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Adversarial review (gemini-4-neon, reviewed 570ad37).

The spec reasoning and all 14 .bidi-text truncation/clamp sites hold up across Chromium, Firefox, and WebKit (including in-place text updates on reused nodes such as HeroOverviewText, and both RTL-with-English and LTR-with-Arabic). Every .bidi-text element in web/src/ cut with truncate, line-clamp, or detailLayout.css is covered, and none of the touched elements carry logical inline utilities or rtl: descendants that dir="auto" would flip.

Three issues came up in the inline comments: one medium documentation conflict in web/src/i18n/README.md (PR #4783 already merged into the base commit, leaving two directly contradicting rules ten lines apart), and two low-severity issues in DetailTitle.tsx and DetailOverview.tsx.

Comment thread web/src/i18n/README.md Resolved
<div className="detail-hero-description max-w-2xl">
<p
ref={textRef}
dir="auto"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

G3 (low): dir="auto" regresses clamped mixed-script multi-paragraph descriptions in CollectionPageHero

  • Trigger: A collection description with line breaks (web/src/components/collections/CollectionPageHero.tsx:96-98 wraps <DetailOverview clamp /> in whitespace-pre-line) whose opening line is in the opposite script from a longer body paragraph clamped on line 3 — e.g. an English heading on line 1 followed by an Arabic description in Arabic UI, or an Arabic heading on line 1 followed by an English description in English UI.
  • Impact: Under CSS Writing Modes 3, unicode-bidi: plaintext picks a base direction per \n-delimited paragraph, whereas HTML dir="auto" sets one direction on <p> from the first strong character of paragraph 1. Before this change, a clamped body paragraph in the page's language matched <p>'s inherited direction and ellipsized at its end in Firefox and WebKit. With dir="auto", paragraph 1 flips <p>'s direction against paragraph 2: in Firefox 153 both cases clip the start of line 3 and draw "…" at its start edge; in WebKit 26.5 the RTL+English-heading case drops "…" and the LTR+Arabic-heading case clips the start of line 3.
  • Evidence: Verified before/after in Playwright Firefox 153 and WebKit 26.5 on <div dir="rtl" class="whitespace-pre-line"><p dir="auto" class="bidi-text line-clamp-3"> and its dir="ltr" mirror, matching CollectionPageHero.tsx:96-98 + DetailOverview.tsx:75-83.
  • Suggested repair: Single-script opposite-direction descriptions are far more common and clearly benefit from dir="auto", and CSS has no per-paragraph direction property for a single clamped <p>. Document this multi-paragraph limitation in web/src/app.css or CollectionPageHero.tsx so it is a known boundary rather than a surprise.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Confirmed in a three-engine probe: a description with an English first line and an Arabic body, clamped in the Arabic interface, cuts the start of the last line in Firefox and drops the "…" in WebKit. Chromium is unchanged. Keeping dir="auto" here: an all-English or all-Arabic description is the common case, and it is fixed in every engine. As you note, no one direction suits every paragraph of one clamped block. dae14ed adds a comment at the <p> describing the limit, and the PR body lists it under Risks.

🤖 Claude Code (claude-opus-5-5)

…title

DetailTitle set dir="auto" while its caller passed .bidi-text, so a caller
that left the class out would align an English title to the wrong edge in
Arabic. DetailTitle now adds the class itself. Also note on DetailOverview
that one direction can't suit every paragraph of a clamped multi-paragraph
description.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-kody

silo-kody Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@silo-kody

silo-kody Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌
⚠️ 4 Kody Rule(s) were not evaluated

These rules declare that they need repository context beyond this diff, and the review could not retrieve it, so they were not judged on this pull request:

  • Preserve optional store capabilities through production wrappers
  • Detach mandatory cleanup from request cancellation and bound its lifetime
  • Preserve durable media identity and share identity-evidence precedence
  • Bound decoder throughput trades and share direct-play eligibility

…le-ellipsis

# Conflicts:
#	web/src/i18n/README.md
@Quick104
Quick104 merged commit e99fdd2 into main Nov 21, 2026
18 checks passed
@Quick104
Quick104 deleted the fix/rtl-truncated-title-ellipsis branch November 21, 2026 05:37
Quick104 added a commit that referenced this pull request Nov 21, 2026
Main now gives every cut .bidi-text element dir="auto" (#4853), so Firefox
and WebKit keep the start and the ellipsis of an English title in a
right-to-left interface. The pinned shortcut label is cut with truncate.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Quick104 added a commit that referenced this pull request Nov 21, 2026
…#4909)

* fix(web): show the sidebar's unpin button to keyboard and touch users

The unpin button on pinned library shortcuts only appeared on mouse hover,
so Tab focused an invisible button and touch screens never showed it while
it still took taps at the end of the row. It now uses the shared
pointer-reveal utility, and on touch the link reserves room so a long
label truncates before the button instead of running under it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(web): keep pinned labels clear of the unpin button while it shows

Under a mouse the label now gives up the button's room only while the row
is hovered or focused, so the ellipsis lands before the icon instead of
under it, and labels keep their full width at rest. The button now spans
the row's height and 28px of its end, a larger tap target with the icon
where it was.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(web): keep pinned label direction and the unpin focus ring tidy

The pinned label takes its direction from its own text, so an English
title in a right-to-left interface truncates at its end. The unpin
button's focus ring wraps the icon instead of the button's full-height
hit area.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(web): give the sidebar unpin button its own 24px box and focus ring

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(web): ignore a tap that lands on a hidden hover-only control

On a hybrid last used with a mouse, `.pointer-reveal` controls are hidden
but still take hits. A touch on one clears the fine-pointer flag, which
reveals the control before the tap's click arrives, so the first touch at
the end of a pinned sidebar row unpinned it. A press that starts on a
hidden control now drops its click; keyboard activation and taps on a
visible control are unchanged. The sidebar unpin button also stops
fading, so it never shows over a label that has just reclaimed its room.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* refactor(web): note a hidden-control press in the flag's own listener

Record the press at the top of onPointer, before the flag changes, so the
guard no longer depends on a window listener running ahead of the
document one.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* fix(web): give the truncated pin label dir="auto"

Main now gives every cut .bidi-text element dir="auto" (#4853), so Firefox
and WebKit keep the start and the ellipsis of an English title in a
right-to-left interface. The pinned shortcut label is cut with truncate.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>

@Quick104 Quick104 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Adversarial review (gpt-6.2-sol, reviewed 570ad37)

The single-line fix worked in my browser reproduction. The collection description regression and the README wording are on the changed lines below.

<div className="detail-hero-description max-w-2xl">
<p
ref={textRef}
dir="auto"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

S1 [P2] Preserve the cutoff in bilingual collection descriptions. CollectionPageHero preserves line breaks with whitespace-pre-line. In an English interface, a short Arabic intro followed by a long English paragraph sets the whole element's direction from the intro. Firefox 153 and WebKit 26.5 then cut the start of the last visible English line. In a before-and-after render of the collection hero with a 306 px text column, across the mountains with a company of ol… became …ross the mountains with a company of old. Keep the inherited direction for collection descriptions with preserved line breaks and use dir="auto" for single-paragraph clamps.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Confirmed; this is the same trade-off Gemini raised on this line. Keeping the page's direction for descriptions with line breaks would fix a bilingual description, but it would bring back the original bug for a one-language description with paragraphs, such as an all-English description in Arabic. The merged change keeps dir="auto" and documents the limit at DetailOverview and under Risks. Whether to change that is a maintainer decision, so I'm leaving this thread open.

🤖 Claude Code (claude-opus-5-5)

Comment thread web/src/i18n/README.md Resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working impact: polish Annoyance, cosmetic, or nice-to-have javascript Pull requests that update javascript code priority: P2 Limited scope, workaround exists, or polish size/M 50–199 added + deleted lines (all files); change volume, not priority.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant