Repository navigation
fix(web): show the admin Users table only when it fits - #5191
Conversation
At 1024 px the admin sidebar leaves the Users page 720 px, but its table switched in at Tailwind's lg breakpoint and needs about 880 px, so the last columns, including the row actions, sat behind a sideways scroll. The Users page now switches from its compact rows to the table at xl (1280 px), the breakpoint the wide Libraries diagnostics tables already use. Usernames, emails and group names wrap, so a long one no longer pushes the action buttons out of view at that width. The shared hook is renamed to useWideTableLayout now that it is not diagnostics-only. Closes Silo-Server#5062
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
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:
|
…eft pages The email cell now wraps; give it the emailDir direction and the align-with-page sizing the compact rows and other admin email cells use, and point the compact list's comment at the new xl switch. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Users now shows its compact rows, and the Sort control, from lg to xl, where the search box and group filter beside it drop to their desktop height. Give the Sort control the same lg touch rule instead of a fixed 44px, so the filter row lines up. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Quick104
left a comment
There was a problem hiding this comment.
🤖 Claude Code (claude-opus-5-5)
Review of 4104944. The breakpoint change works: on a sandbox built from this head, the Users table no longer overflows at 1024, 1152, 1280, or 1440 px, in English or Arabic. I found two small issues, both low severity, and I'm fixing both in commits on this branch, so there's no need to change anything yourself.
One more nit, outside the diff: the doc comment on AdminUserCompactList still says it's the list "below the lg breakpoint". I'm updating it to xl in the same commit.
From lg to xl the search box, group filter and Sort control shared one row, which squeezed the search box until its placeholder was cut off. Stack them as below lg until the table shows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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:
|
At 1280 px the email column is squeezed, and wrap-anywhere cut ordinary addresses mid-word (alice@example.co / m). Give the email break points after the @ and before each dot, so it wraps between its parts and only cuts a part that can't fit on its own. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With the email breaking at its parts, the table squeezed the group column instead and cut "Default Group" mid-word. Give the group cell a 6rem minimum, so ordinary words stay whole and the username and email give way first; a longer name still breaks inside that width. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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:
|
|
🤖 Claude Code (claude-opus-5-5) Review summaryReviewed head: ed18ebe (the author's 4104944 plus five review commits on this branch). The fix works. On a sandbox built from this branch, the Users table no longer runs off the page. The seeded data includes a very long username and email and a long one-word group name. With that data, the base frontend overflowed its container by 795 to 1208 px at 1024, 1152, 1280 and 1440 px. At ed18ebe the overflow is 0 at every one of those widths and at 390 px, in English and Arabic. Below 1280 px the page shows the compact rows; from 1280 px the table shows every column and all of its row actions. Evidence: https://evidence.siloserver.org/r/silo-server/pr-5191/ Fixed on this branch
Left as is
Not caused by this PR: in the compact rows, an action menu item that names a very long username is clipped (the item needs 451 px and gets 246 px). The compact list already did this below 1024 px; this PR also shows it from 1024 to 1279 px. Checks
Council
VerdictFit: 9/10 · Readiness: 9/10 — ready Fit: this is a polish fix for an admin page that hid its own controls. It reuses the breakpoint the Libraries diagnostics tables already use, adds no setting, and costs nothing at runtime. Readiness: the overflow was reproduced on the base and is gone on this head, in two languages and at five widths. The validation-board check ran, and no defect from the review is left open. |
Problem
Closes #5062
Related issue: N/A
Validation tasks: changes #1197 C1 (the Users list shows compact rows instead of the table from 1024 to 1279 px)
Other clients: Apple N/A (no client-visible change); Android N/A (no client-visible change); Roku N/A (no client-visible change)
On the web admin Users page, the users table replaced the compact rows at 1024 px. At that width the admin sidebar leaves the page 720 px, and the table needs about 880 px with short names, so the last columns, including the row actions, sat behind a sideways scroll with no visible cue. This change keeps the compact rows until 1280 px, where the table fits, and lets long usernames, emails and group names wrap so they cannot push the actions out of view.
Approach
The Users page now uses the same
xl(80rem) switch the wide Libraries diagnostics tables got in #5063. That hook moves from the nameuseWideDiagnosticsTableLayouttouseWideTableLayout, since it is no longer diagnostics-only; the three diagnostics sections only pick up the new name.Below 1280 px the page shows the compact rows and the Sort control it already shows below 1024 px. The username and group links wrap with
dir="auto"andalign-with-page, following the right-to-left rules inweb/src/i18n/README.md, and the email cell wraps too. Without the wrapping, a single long username or email made the table about 1190 px wide, wider than the page even at 1440 px. The broader Extra Large text rework in #5071 is left out.Review fixes on this branch:
dir={emailDir(email)}like the compact rows and the other admin email cells, so123@example.comno longer readsexample.com@123in Arabic. It also breaks after its@and before its dots (BreakableEmail), not mid-word.SortControlnow uses the sharedlgtouch rule instead of a fixed 44 px, so it matches the controls beside it. Its other caller, the Skipped Roots cards, also gets 36 px controls from 1024 to 1279 px.Validation
make test-web: pass.verify-local-paths,verify-bidi,verify-case-collisions,verify-size-ratchet: pass.scrollWidth - clientWidth), English and Arabic:With short names only, the 1024 px table overflowed by 160 px, the figure the issue reports.
Review verification at ed18ebe, on a sandbox built from the branch, with the base frontend served from the merge base against the same API: seven synthetic accounts, including a very long username and email,
123@example.com, an Arabic username, and a long one-word group name. Overflow is 0 at 1024, 1152, 1280, 1440 and 390 px in English and Arabic. On the base it is 795 to 1208 px. A standalone check confirmed that Chromium, Firefox and WebKit all honor the group cell's minimum width. The web typecheck, eslint, prettier and the admin vitest suites (16 files, 122 tests) pass.Evidence
Evidence: https://evidence.siloserver.org/r/silo-server/pr-5191/
Surface and build: web admin, Users page, local build of this branch against its base, desktop at 1024 px and 1440 px, mobile web at 390 px (unchanged).
Risks
None identified. Admins on 1024 to 1279 px screens see the compact rows instead of the table.
Checklist
Council review
Rounds: 3, last reviewed ed18ebe
Visual review: 2 rounds, captures from 681d8dd and ed18ebe
Fixed: the email direction and its mid-word breaks, the filter row's mixed control heights and squeezed search box, a group name cut mid-word, and the compact list's stale
lgcomment. Answered: Extra Large text (tracked in #5071), the compact layout's missing group link and creation date (the existing compact design), the cross-engine support for the group cell's minimum width (checked in Chromium, Firefox and WebKit), and the shared Sort trigger and chevron styling (unchanged from before this PR).AI Disclosure
isDesktopflag toshowTable, corrected a comment that still saidlg, and gave the wrapping username and group linksdir="auto"andalign-with-pageper the i18n README. A re-review of those changes found nothing. Dropped: a suggestion to stop listing the hook's callers in its comment (kept, matches the existing style).Note
Show admin Users table only when it fits, with breakable email wrapping
SortControlrenders when the table is hidden.@and before dots via the newBreakableEmailhelper in AdminUserRowParts.tsx, plusemailDirdirection handling.useWideDiagnosticsTableLayouttouseWideTableLayoutin diagnosticsListState.ts and updates the diagnostics sections and the Users page to call it. The breakpoint query is unchanged.SortControlin DiagnosticsListParts.tsx keeps 44px touch sizing only below lg instead of at all widths.Macroscope summarized ed18ebe.