Repository navigation
fix(web): keep restore checkboxes and profile icons on the first line of wrapped text - #4723
Conversation
… of wrapped text Three backup restore rows centered their leading marker on the whole text block, so it sat between lines once the text wrapped: the data type checkboxes on the Choose step, the "I trust this backup" checkbox on the Review step, and each profile's outcome icon in the Run step's report. Each marker now sits in a box one line tall at the top of its row, as the Choose step's chevrons do. One-line rows keep their position. A wrapped data type label also stood its count apart as a separate flex item, and a profile's outcome did the same beside a wrapped name; both now flow with their text. The count avoids ending up alone on the last line, and the outcome wraps as a unit so its "·" stays with the word it introduces. The profile icon no longer shrinks, and the trust label takes the box's line height instead of packing wrapped lines tight. 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 41 minutes. View limit details
|
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. |
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:
|
… fonts The checkbox and outcome icon are sized in rem, so a large browser default font makes them taller than the 13 px line their box was sized to; the box now grows with them instead of letting a checkbox overlap the row below and take its clicks. The profile outcome was unbreakable, so a long translated outcome at large text ran past a narrow screen; it still moves to the next line as a unit but can now wrap inside itself. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Quick104
left a comment
There was a problem hiding this comment.
Adversarial review (Gemini 4 Neon, reviewed 7f51ef6)
The three changed rows hold up against Tailwind CSS 4.2.1 (h-lh, leading-5, text-pretty, me-1.5, whitespace-nowrap), tailwind-merge 3.5.0 (text-[13px] drops Label's leading-none), eslint-plugin-formatjs (no-literal-string-in-jsx rejects {" "} inside a JSX element), label association, and RTL layout. One remaining row in the same restore step still has the same bug.
G1 (low) — web/src/pages/admin-backups/RestoreRun.tsx:271-278 (outside diff)
- Trigger: Step 3 (
RestoreRun) while the job is non-terminal (!job.terminal) and either canceling (web.admin.backups.restore.run.stopping:"Stopping after the current item…"in English, 39–43 characters ines/de/ca) or queued in longer translations (ca/lv/pl/hi), on a 320 px viewport or at 125% text scale. Inside<main>(--page-gutter: 1rem) and.surface-panel(p-5plus a 1 px border), the status row has 246 px total width at 100% text scale (222 px after thesize-4icon andgap-2) and 228 px at 125% (198 px for text), so those strings wrap to two lines. - Impact: The status row uses
flex items-center gap-2 text-sm font-medium, which centers<LoaderCircle>vertically between the two lines instead of keeping it on the first line. Because<LoaderCircle>also omitsshrink-0and browser UA stylesheets setoverflow: hiddenon non-root<svg>elements (settingmin-width: autoto0in Flexbox), flex overflow when the text wraps can also shrink the spinner belowsize-4. - Evidence:
web/src/pages/admin-backups/RestoreRun.tsx:271-278renders<div className="flex items-center gap-2 text-sm font-medium">with<LoaderCircle aria-hidden="true" className="size-4 motion-safe:animate-spin" />, right below theAccountReportfix in the same file. - Suggested repair: Use the same one-line marker wrapper as
AccountReport:
<div className="flex items-start gap-2 text-sm font-medium">
<span className="flex h-lh shrink-0 items-center">
<LoaderCircle aria-hidden="true" className="size-4 motion-safe:animate-spin" />
</span>text-sm sets line-height: 1.25rem, so h-lh matches one line at every root font size and leaves single-line states ("Restoring…") unchanged.
AI-assisted review: Gemini 4 Neon via Antigravity in T3 Code.
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:
|
…r fonts The data type checkbox and profile icon are sized in rem while their text is 13 px, so at a large browser default font the marker's box grew past the text line and a one-line label sat near the box's top instead of beside the marker's center. These rows' line height is now never shorter than their marker, so the marker and the first line share a center at every font size. At the default size the line height is unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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:
|
The previous commit gave the data type and profile rows a line height in px and the trust row one in rem. A browser's minimum font size enlarges the glyphs but not a fixed line height, so wrapped lines overlapped. The data type and profile rows now set their text in rem with a unitless line height, so text and rem-sized marker grow together and the line stays taller than the marker at any font size, and the trust label takes the box's own unitless text-sm line height. At the default size nothing moves. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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:
|
…markers #4723 gave the restore checkboxes and outcome icons a box at least one line tall (min-h-lh). The progress spinner's box now uses the same class. Its line is always taller than the spinner, so the layout doesn't change. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ped status text (#4746) * fix(web): keep the restore progress spinner on the first line of wrapped status text The Run step's status row centered its spinner on the whole status text and let flexbox squeeze it. When the text wraps, as Spanish "stopping" does at 320 px and most translations do at the x-large text size, the spinner sat between the lines at a reduced width. The row now aligns to the top and holds the spinner in a box one line tall that doesn't shrink, as the other restore rows do. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(web): let the restore status text break inside a word when it can't fit With the spinner no longer shrinking, a status word wider than the space beside it ran past the panel. At 320 px with a 24 px browser font and the x-large text size, Russian "Восстановление…" was cut off. The status text may now break inside a word when nothing else fits; rows whose words fit are unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]> * refactor(web): size the restore spinner's box like the other restore markers #4723 gave the restore checkboxes and outcome icons a box at least one line tall (min-h-lh). The progress spinner's box now uses the same class. Its line is always taller than the spinner, so the layout doesn't change. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
Problem
Related issue: N/A
Validation tasks: none
Other clients: N/A (the backup restore screen exists only in the web admin)
Three rows in the backup restore flow put a marker in front of text that can wrap, and each centered the marker on the whole text block, so a wrapped row's marker sat between its lines:
#4694 fixed the same problem for the Choose step's chevrons and restart badge. This change keeps each of these three markers level with the first line of its text. Rows that fit on one line don't move.
Approach
Each row now aligns to the top, and its marker sits in a box at least one line tall, the pattern #4694 used. The checkbox and icon are sized in rem, so the data type and profile rows now set their text in rem too (
0.8125rem, 13 px at the default size) with a unitless line height: text, line, and marker grow together at any browser font size, and a browser's minimum font size still spaces wrapped lines. The trust row uses its box's own unitlesstext-smline height. The never-restored lock and blocked-group dot from #4680 use a margin instead; this change leaves them alone.Three wrapping details changed with it:
text-wrap: prettykeeps the count from ending up alone on the last line where the browser supports it.Label'sleading-none, so its wrapped lines sat 14 px apart. It now uses the 20 px line height of the paragraph above it.Validation
main, with a user whose 64-character profile name wraps and whose ratings and favorites give the data types counts. The restore set'sauthenticatedflag was set to false in the browser to show the Review step's trust box, since a backup the server can't authenticate only arrives as an upload from another server. Wrapped data type checkboxes sat 10.5 to 20.25 px below their first line at 1024 px, the trust checkbox 7 px (18.25 px at x-large text), and profile icons 10.5 px (20.25 px at 320 px, 24.8 px at x-large text).Evidence
Evidence: https://evidence.siloserver.org/r/silo-server/restore-wrapped-checkboxes/
Risks
text-wrap: prettyyet, so a count can still end up alone on a line there. The marker alignment doesn't depend on it.Follow-ups
Checklist
Council review
Background review: 3 rounds; round 3 on 7e0f6e6
Background review, round 1: Sol found that at large browser default fonts a data type checkbox outgrew its one-line box and overlapped the next row (a click near its bottom toggled the wrong option), and that the unbreakable outcome could run past a 320 px screen. Both are fixed in 3003106. In round 2, Sol found that a one-line label then sat above its taller checkbox's center at large fonts; 7e0f6e6 fixes that. Opus and Gemini found nothing new. In round 3, Sol found that the fixed line heights 7e0f6e6 used let wrapped lines overlap under Firefox's minimum font size; 96e27db fixes that and is the head. Opus noted that 7e0f6e6's line-height floor duplicated the marker sizes, which 96e27db removes. Gemini's round 3 didn't run: its provider quota ran out. Sol's reviews didn't post because the review tool couldn't attach them to the commit. Single-word German and Finnish outcomes still run past a 320 px screen at a 40 px browser font with x-large text, as they do on
main. Opus found nothing. Gemini found the restore progress spinner centering on wrapped status text, which behaves the same onmain; it has its own follow-up.Visual review: 2 rounds, captures from 7f51ef6
Fixed: all three members found a data type's count alone on a line at 1440 px, and a profile outcome's "·" stranded at a line's end while "Created" wrapped to the next. The label now uses
text-wrap: pretty, and the outcome wraps as a unit.Answered:
AI Disclosure
🤖 Generated with Claude Code
Note
Fix checkbox and icon alignment on first line of wrapped text in restore pages
Fixes vertical alignment in the admin backup restore pages so checkboxes and profile icons sit on the first line when text wraps.
Macroscope summarized 7f51ef6.