Skip to content

fix(web): let a restore row name use the room a short detail leaves - #4978

Merged
Quick104 merged 1 commit into
mainfrom
fix/restore-row-name-width-cap-1
Nov 21, 2026
Merged

Quick104 merged 1 commit into
mainfrom
fix/restore-row-name-width-cap-1

Conversation

@Quick104

@Quick104 Quick104 commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Closes #4791
Related issue: N/A
Validation tasks: none

Other clients: Apple N/A (no backup restore screen); Android N/A (no backup restore screen); Roku N/A (no backup restore screen)

On the backup restore Choose step, a row wide enough to show its name and its detail on one line cut the name at 60% of the line (45% for an account) whenever any detail sat beside it, however short. A long collection name beside "adds 3 items" ended in "…" with empty space after the detail, and a long username was cut beside a short email. Now the name uses the room a short detail doesn't need, and it is cut only when the name and the detail together don't fit.

Approach

The name and the detail share the line 3:2 (9:11 for an account), starting from zero width, and neither grows past its own text. When one reaches the width of its text, flexbox hands the room it doesn't need to the other. So the name gets its share, plus whatever a short detail leaves. When both are longer than their shares, the split is the old 60% (45%), so a long name still can't push out a long folder path or email. Rows below 42rem, where the detail sits under the name, are unchanged. It is CSS only, with no measuring script.

Validation

  • Reproduced on a dev sandbox built from main, with a real backup: a collection with a long name lost 3 items after the backup, and two accounts were deleted. At 1366 px the collection name stopped at 327 of its 402 px beside "adds 3 items", with 138 px empty after the detail. It was also cut at 1440 px and at 820 px.
  • On the same sandbox rebuilt from this branch, with the same data and steps: the collection name and the short-email account name show in full at 1366, 1440 and 820 px. The account with a long name and a long email still splits about 45/55, both cut. Rows at 390 px are unchanged, Arabic (right to left) behaves the same, and the console shows no errors.
  • With the row's text swapped in the browser on the fixed build: a long name beside a long folder-path detail stops at 60%, and a name too long even beside "adds 3 items" ends where the detail starts. At 390 px the page doesn't scroll sideways.
  • The same flex rule in a static page gives the same widths in Chromium, Firefox and WebKit.
  • Web lint, format check, type check, production build and bundle budget pass, as do make verify-local-paths, verify-bidi and verify-case-collisions.
  • The web test suite passes 3099 tests and fails 33 in 7 files (player, API request deadline, auth refresh, admin collections), none of which imports these rows. Four of those files fail on main too; the other three pass when run on their own.

Evidence

Evidence: https://evidence.siloserver.org/r/silo-server/issue-4791/

Risks

None identified. Layout only, on one admin screen.

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

Plan round: skipped. The cause sits in two class lists and the fix changes only those.

Background review: running on 18140bf

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

Visual review: 2 rounds, final captures match 18140bf

Member Round 1 Round 2
Sol better, 9/10 better, 9/10
Opus better, 9/10 better, 9/10
Gemini better, 8/10 not run

Gemini's round 1 hit a quota limit and its retry finished after round 2 had started; round 2 added the captures it asked for. Answered: when the name and the detail are both long, the name is 3 px narrower than before, because the shares now leave out the gap between them (all three). The space after an ellipsis is wider than the gap, as before this change (Opus). Added: a long name beside a long detail, a name too long even beside a short detail, and a phone-width page check. The summary card cutting "Home and library sections" short predates this change; a separate fix is underway.

AI Disclosure

  • Harness: Claude Code in T3 Code
  • Tool(s): Claude Code and its review subagents; T3 Code delegated tasks for the council (Codex, Claude, Antigravity); Playwright (headless Chromium, Firefox, WebKit) for captures and the static check
  • Model(s): claude-opus-5-5 (implementation, captures, code review); claude-sonnet-5-5 (code-review cleanup finder and validation check); gpt-6.2-sol, claude-opus-5-5, gemini-4-neon (visual and background reviews)
  • Involvement: Fully AI-generated. The agent verified it live on a dev sandbox; a person has not verified it yet.
  • Adversarial review: code review at xhigh (three finders, a validation check and a sweep) found no defects and three comment wording fixes, all applied. See Council review for the visual and background reviews.

🤖 Generated with Claude Code

Note

Fix restore row name/detail width split with max-content caps

Both restore row layouts change how the label and secondary text share space at the @2xl container breakpoint. Each text is capped at its max-content width, so one side can use space the other does not need.

  • ItemRow in RestoreRows.tsx: label and detail now split space 3:2
  • AccountRow in RestoreUsers.tsx: label and contact now split space 9:11
  • Truncation and label word-break hiding are unchanged; both texts still truncate when short on space

Macroscope summarized 18140bf.

On the backup restore Choose step, a one-line item row stopped its name
at 60% of the line (45% for an account) whenever a detail sat beside it,
even a short one such as "adds 3 items", and left empty space after the
detail. The name and the detail now share the line 3:2 (9:11 for an
account) from a zero basis, each capped at its own width, so whichever
needs less gives the rest to the other. A name still stops at 60% (45%)
when both are longer than their shares.

Closes #4791

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 32 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: bed7418a-0fce-4f87-835f-fb343edd59e3
Commits

Reviewing files that changed from the base of the PR and between 34384f9 and 18140bf.

Files selected for processing: 2

  • web/src/pages/admin-backups/RestoreRows.tsx
  • web/src/pages/admin-backups/RestoreUsers.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-21T08:12:15.939027Z 18140bf PR opened
🔒 Security Review ✅ Completed 2026-11-21T08:14:03.822700Z 18140bf PR opened
ℹ️ 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.

@silo-triage silo-triage Bot added bug Something isn't working impact: polish Annoyance, cosmetic, or nice-to-have priority: P2 Limited scope, workaround exists, or polish triaged High-confidence review completed; does not mean fixed, validated, or accepted for release. labels Nov 21, 2026

@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 18140bf)

I found no recorded v1.0 validation case that exercises either changed row.

AI assistance from Codex (gpt-6.2-sol).

className={cn(
"block max-w-full shrink-0 text-sm font-medium wrap-anywhere",
secondary && "@2xl:max-w-[60%] @2xl:truncate @2xl:[&_wbr]:hidden",
secondary && "@2xl:max-w-max @2xl:flex-3 @2xl:truncate @2xl:[&_wbr]:hidden",

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 (P3) — A long detail can hide the end of a name that previously fit. The new split subtracts the 8 px gap before assigning both shares. A name that falls between the old cap and its new share now gets an ellipsis. I reproduced this in Chromium, Firefox, and WebKit using the row classes and UI font. In a 686 px library row, a long path reduced the name from about 334 px to 329 px and hid the end of “Volume Two.” In an 808 px account row, a long contact reduced the name from about 216 px to 213 px and hid the username’s .01 suffix. The account rule is in RestoreUsers.tsx:250.

Use a starting flex basis of 60% for the name (45% for accounts) and the remaining percentage minus 0.5rem for the detail. With both items allowed to grow and capped at max-content, those bases preserved the full names in the reproductions and still gave long names the space left by short details.

@Quick104
Quick104 merged commit ae610da into main Nov 21, 2026
23 checks passed
@Quick104
Quick104 deleted the fix/restore-row-name-width-cap-1 branch November 21, 2026 08:32
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 priority: P2 Limited scope, workaround exists, or polish size/S 0–49 added + deleted lines (all files); change volume, not priority. triaged High-confidence review completed; does not mean fixed, validated, or accepted for release.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] Restore rows stop a name at 60% beside a short detail, next to empty space

1 participant