Skip to content

improve(ui): tighten mobile side rail - #189470

Merged
vyctorbrzezowski merged 1 commit into
mainfrom
brzezowski/mobile-side-rail
Oct 31, 2026
Merged

vyctorbrzezowski merged 1 commit into
mainfrom
brzezowski/mobile-side-rail

Conversation

@vyctorbrzezowski

@vyctorbrzezowski vyctorbrzezowski commented Oct 31, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

The mobile web side rail reads as oversized: the new-session button is much larger than every other rail member, and spacing between controls and blocks is loose and uneven.

User Impact

User impact: the mobile rail is narrower and calmer, with a new-session button that matches the avatars, and all items stay reachable. Icon glyphs keep their size. Rail hit areas go from 44px to 36px on mobile, with 4px between them.

Why This Change Was Made

The rail now takes its size from one visual system on mobile: 36px controls, 30px filled members (avatars, new session, Home ring), a 40px step inside a block and 8px of space around block edges. All controls share one center line, and corner radii follow each theme's scale, so CRT stays square. On short viewports the pinned list gives up its height first, and the rail scrolls once that runs out, so the footer is no longer cut off. Rails outside the mobile layout keep their current values.

Evidence

Mock at 390px with seven pinned pages and an inbox count.

Absolutely dark, 390x844

Before After

Absolutely light, 390x844

Before After

Absolutely dark, 390x600

Before After

Absolutely light, 390x600

Before After

After, CRT dark and Beacon light, 390x844

CRT Beacon

Measurements at 390x844, Absolutely dark

Item Before After
Rail width 52px 48.5px
Top avatar control / fill / center x 44 / 30 / 26 36 / 30 / 24
New session button / center x 44 / 25.5 30 / 24
Divider width 44px 36px
Page and footer controls / center x 44 / 25.5 36 / 24
Glyphs: page icons / Home 19 / 16 19 / 16
Step between controls in a block 52px 40px
Bottom avatar fill / center x 30 / 25.5 30 / 24
Presence dot, inbox count 12, 14 12, 14
Overlapping hit areas 0 0

Short viewports: at 390x420 the rail content needed 525px of 404px before and the footer was cut off; it now fits. At 390x340 the rail scrolls and the pinned list collapses to a sliver, so pinned pages are reached from the Pages view at that height. CRT radius on rail controls measures 2.5px.

Checks: stylelint and oxfmt pass. Vitest passes for app-sidebar-rail (35), the rail menu, inbox badge and session glyph browser tests (8), and the sidebar-rail and sidebar-account-footer e2e tests (6). No tests encoded the old geometry. Those ran before a final rebase onto current main, with the same CSS. Not checked on a physical phone.

Landing verification

The current head passed all applicable non-budget checks in CI run 41211588034. Independent source review found no actionable P0–P2 correctness defects, and the published normal/short mobile screenshots were inspected. The desktop connection flag is disabled in mobile layout by the existing shell owner, so the rail's new overflow does not clip that feedback.

The remaining ClawSweeper finding and CI failure are only the CSS asset ceilings: 309404 versus 309366 bytes gzip, and 1600618 versus 1599319 bytes raw. This landing uses the maintainer-approved CSS-budget exception. No design values or budgets were changed; no additional tests were added.

@vyctorbrzezowski vyctorbrzezowski self-assigned this Oct 31, 2026
@clawsweeper

clawsweeper Bot commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 31, 2026
@clawsweeper

clawsweeper Bot commented Oct 31, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs changes before merge.

What this changes

This PR narrows the mobile sidebar rail, reduces control spacing, and adds scrolling for short screens.

Example: Open the navigation drawer at 390×844 with seven pinned pages.

  • Before: The new-session button measures 44px and controls have a 52px vertical step.
  • After: The new-session button measures 30px and controls have a 40px vertical step.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) Useful, owner-directed visual refinement with directly inspected screenshots, held back by a concrete CSS performance-gate failure.
Proof confidence 🐚 platinum hermit (4/6) ✨ media proof bonus Sufficient (screenshot): Inspected before-and-after Control UI screenshots with synthetic data at 390×844 in dark and light themes show the changed rail width, button sizes, spacing, and visible footer.
Patch quality 🦐 gold shrimp (3/6) 1 actionable review finding remain.

Product

Kind: Preference · Worth it: Yes · Fix scope: Complete
User problem: The mobile rail has an oversized new-session button and loose spacing that consumes scarce drawer space.
Reason: The maintainer author has substantial prior rail ownership and explicitly accepts the smaller mobile touch targets and short-screen shortcut tradeoff.

Merge readiness

⛔ Needs changes before merge - 1 item remains

Keep open: this maintainer-authored PR provides useful mobile polish, but its added CSS exceeds enforced asset budgets and blocks CI.

Priority: P3
Reviewed head: caa3f8c4d9677ed840023d0f6cb9767b23cb526c

Before merge

  • Bring the added rail CSS within the enforced asset budgets (P2) - The mobile rules increase the built CSS beyond both enforced ceilings. The exact-head performance check reports 1563.1 KiB raw versus a 1561.8 KiB limit and 302.2 KiB gzip versus 302.1 KiB, which also fails the aggregate CI gate. Reduce or consolidate the added styling while preserving the demonstrated layout, then verify the same performance check passes.

Findings

  • [P2] Bring the added rail CSS within the enforced asset budgets — ui/src/styles/sidebar-rail.css:579-589
Agent review details

How this fits together

The Control UI sidebar renderer supplies navigation controls and pinned shortcuts; the shared rail stylesheet determines their mobile dimensions, spacing, and overflow.

flowchart LR
  A[Viewport and input] --> B[Shell layout class]
  C[Sidebar renderer] --> D[Navigation rail]
  B --> E[Rail stylesheet]
  E --> D
  D --> F[Pages and account actions]
Loading

Technical review

Best possible solution:

Preserve the approved mobile geometry in the existing stylesheet while reducing its asset cost enough to satisfy the current budgets.

Do we have a high-confidence way to reproduce the issue?

Current-main CSS retains 44px coarse-pointer controls and 8px gaps, matching the oversized layout visible in the submitted before screenshots.

Is this the best way to solve the issue?

The change uses the existing stylesheet and sizing variables without adding another rendering or state owner; the concrete remaining defect is its asset-budget failure.

Full review comments:

  • [P2] Bring the added rail CSS within the enforced asset budgets — ui/src/styles/sidebar-rail.css:579-589
    The mobile rules increase the built CSS beyond both enforced ceilings. The exact-head performance check reports 1563.1 KiB raw versus a 1561.8 KiB limit and 302.2 KiB gzip versus 302.1 KiB, which also fails the aggregate CI gate. Reduce or consolidate the added styling while preserving the demonstrated layout, then verify the same performance check passes.
    Confidence: 0.97

Overall correctness: patch is incorrect
Overall confidence: 0.94

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 09530a1eb38b.

Provenance checked

Testing

Proof path: shipped entry point.

Security

None.

Evidence

Acceptance criteria:

  • pnpm ui:check-performance:base 5dd76f0
  • pnpm exec stylelint --config config/stylelint.config.mjs ui/src/styles/sidebar-rail.css
  • pnpm exec oxfmt --check ui/src/styles/sidebar-rail.css
  • Inspect the rendered mobile rail at 390×844, 390×600, and 390×340, including footer access and pinned-shortcut overflow.

What I checked:

  • Verified introduced change: The introduced diff changes only the rail stylesheet; comparison with fetched main confirms the mobile rules remain unique to this PR. (ui/src/styles/sidebar-rail.css:579, caa3f8c4d967)
  • Exact-head CSS budget failure: The performance check reports total CSS raw at 1563.1 KiB against 1561.8 KiB and gzip at 302.2 KiB against 302.1 KiB; the CI gate explicitly identifies this failed check. (scripts/check-control-ui-performance.mts:1, caa3f8c4d967)
  • Visual evidence inspected: The four prepared dark/light before-and-after screenshots visibly support the tighter layout at 390×844. Additional short-screen and theme images could not be inspected: scratch writes were rejected as read-only and browser retrieval returned Cache miss; this is a reviewer infrastructure limitation. (caa3f8c4d967)
  • Existing owner and accepted direction: The author also authored the merged rail unification in improve: unify sidebar rail icons and controls #179214, which retained 44px touch targets; this PR explicitly explains its mobile-only reduction and short-screen tradeoff. (ui/src/styles/sidebar-rail.css:81, d9a9caeee4b3)
  • Rail ownership history: Feature history identifies the original compact rail, the subsequent shortcut and overflow refactor, and the later unified control sizing rather than relying only on recent blame. (ui/src/styles/sidebar-rail.css:96, 09530a1eb38b)

PR surface

Source +54. Total +54 across 1 file. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 1 59 5 +54
Tests 0 0 0 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 1 59 5 +54

Labels

Label changes:

  • add P3: This is localized mobile layout polish; the CI failure does not establish an urgent user-facing regression.
  • add proof: sufficient: Contributor real behavior proof is sufficient.
  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🐚 platinum hermit and patch quality is 🦐 gold shrimp.
  • add status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.

Label justifications:

  • P3: This is localized mobile layout polish; the CI failure does not establish an urgent user-facing regression.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🐚 platinum hermit and patch quality is 🦐 gold shrimp.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.
  • proof: sufficient: Contributor real behavior proof is sufficient.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed October 31, 2026, 11:00 AM ET / 15:00 UTC.

@vyctorbrzezowski
vyctorbrzezowski merged commit 2785eda into main Oct 31, 2026
98 of 101 checks passed
@vyctorbrzezowski
vyctorbrzezowski deleted the brzezowski/mobile-side-rail branch October 31, 2026 15:11
roboclaw-bot added a commit that referenced this pull request Oct 31, 2026
Revert 95f5e9a: starting the mobile
host closed hides existing reader, workspace, and active resource panels
when their viewport changes. Restore the previous persistence contract
and defer the automatic session-sheet closure until its callers migrate.

Align the rail assertion with the 48px rail plus default divider approved
in #189470, and record its already approved CSS measurements with the
existing 64-byte variance.

Validated the UI and CI artifact builds, 42 focused mocked browser tests,
the real-Gateway background-work spec, mobile-host and budget tests,
UI types, scoped lint, formatting, and P0-P2 autoreview.

Co-authored-by: steipete <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 1, 2026
Tighten the mobile rail using its existing sizing variables, consistent gaps and theme-scaled corners. Let the pinned area yield height before the rail scrolls so footer controls remain reachable.

Reviewed and validated on caa3f8c. Applicable non-budget CI checks passed; the only exception is the explicitly approved CSS ceiling (+38 bytes gzip, +1299 raw). The approved smaller targets and very-short-screen pinned-shortcut tradeoff are retained.

Co-authored-by: Vyctor H. Brzezowski <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: S status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant