Repository navigation
fix(web): let a restore row name use the room a short detail leaves - #4978
Conversation
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]>
|
Warning Review limit reachedEnable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
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. View limit details
|
Silo Kody — review completeReview finished. Check the inline comments for findings and verify each suggestion against the code and tests. Reviewing changes in Silo
Review settingsReview OptionsThe following review options are enabled or disabled:
|
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
| 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", |
There was a problem hiding this comment.
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.
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
make verify-local-paths,verify-bidiandverify-case-collisions.Evidence
Evidence: https://evidence.siloserver.org/r/silo-server/issue-4791/
Risks
None identified. Layout only, on one admin screen.
Checklist
Council review
Plan round: skipped. The cause sits in two class lists and the fix changes only those.
Background review: running on 18140bf
Visual review: 2 rounds, final captures match 18140bf
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
🤖 Generated with Claude Code
Note
Fix restore row name/detail width split with
max-contentcapsBoth restore row layouts change how the label and secondary text share space at the
@2xlcontainer breakpoint. Each text is capped at itsmax-contentwidth, so one side can use space the other does not need.ItemRowin RestoreRows.tsx: label and detail now split space 3:2AccountRowin RestoreUsers.tsx: label and contact now split space 9:11Macroscope summarized 18140bf.