chore(web): fit the dashboard to 100vh on md+ screens — scroll per component, not globally #228

Closed
opened 2026-04-21 12:28:36 +00:00 by claude-desktop · 0 comments
Collaborator

User story

As an operator, I want the dashboard to occupy exactly one viewport height on medium and large screens, with scrolling handled inside each content region rather than as a single global page scroll, so that the top nav stays visible, the SSE conn pill is always reachable, and long tables / transcripts can scroll without dragging the whole layout with them.

Acceptance criteria

Shell

  • apps/web/src/components/app-shell.tsx — root is flex flex-col min-h-screen. At md: and up: add md:h-screen md:overflow-hidden. The top nav is already 64 px and sticky — keep that; the main region becomes flex-1 min-h-0 md:overflow-hidden so children can own their scroll.

Per-page containers

  • routes/monitor.index.tsx — pipeline list inside a flex-1 min-h-0 overflow-y-auto pane. Header / filters stay pinned.
  • routes/monitor.tasks.tsx — tasks table scrolls vertically inside its own container; the filter strip stays at the top of the region.
  • routes/monitor.grid.tsx — grid body scrolls inside; the sticky column header stays visible.
  • routes/monitor.task.$taskId.tsx — transcript area is the scrolling region; the action bar + metadata strip are pinned (will be revisited when #223 mockup lands, but don't block on it).
  • routes/agents.tsx — agent cards grid scrolls inside.
  • routes/stats.tsx — charts column scrolls; sidebar / header pinned.
  • routes/usage.tsx — breakdown scrolls; header with quota strip pinned.
  • routes/specs.tsx — file list + editor each scroll independently (two-pane layout pattern).
  • routes/planner.board.tsx — per-column scroll already exists for cards; verify the outer shell is 100vh-capped.

Already correct

  • routes/planner.index.tsx already uses h-[calc(100vh-64px)] min-h-0 — keep as reference pattern. Audit other routes against this.

Small screens (< md)

  • Keep today's behaviour — content flows, body scrolls globally. Phones don't get the viewport-cap. Tailwind breakpoint: default md: 768px.

Verification

  • Test matrix:
    • 360×640 (phone portrait) — global scroll, top nav stacks if it needs to.
    • 1280×720 (laptop) — 100vh, per-region scroll, no global scrollbar on html.
    • 1920×1080 (desktop) — same, more breathing room.
  • Playwright: extend apps/web/e2e/monitor.spec.ts with a 1280×720 viewport assertion that document.documentElement.scrollHeight === document.documentElement.clientHeight (no vertical overflow at the page level).
  • Manual smoke: scrolling inside a pipeline list with 40+ rows, the top nav and conn pill stay pinned.

Out of scope

  • Task detail page redesign — covered by #223 Penpot mockup + #224 implementation.
  • Touch-device tweaks beyond the breakpoint switch (inertial scrolling, safe-area insets) — file a follow-up if needed.
  • Any visual restyle — purely layout + overflow.

References

  • apps/web/src/routes/planner.index.tsx:153 — the canonical pattern (h-[calc(100vh-64px)] min-h-0).
  • apps/web/src/components/app-shell.tsx — the shared shell to amend.
  • Tailwind md: breakpoint = 768 px.
## User story As an operator, I want the dashboard to occupy exactly one viewport height on medium and large screens, with scrolling handled **inside each content region** rather than as a single global page scroll, so that the top nav stays visible, the SSE conn pill is always reachable, and long tables / transcripts can scroll without dragging the whole layout with them. ## Acceptance criteria ### Shell - [ ] `apps/web/src/components/app-shell.tsx` — root is `flex flex-col min-h-screen`. At `md:` and up: add `md:h-screen md:overflow-hidden`. The top nav is already 64 px and sticky — keep that; the main region becomes `flex-1 min-h-0 md:overflow-hidden` so children can own their scroll. ### Per-page containers - [ ] `routes/monitor.index.tsx` — pipeline list inside a `flex-1 min-h-0 overflow-y-auto` pane. Header / filters stay pinned. - [ ] `routes/monitor.tasks.tsx` — tasks table scrolls vertically inside its own container; the filter strip stays at the top of the region. - [ ] `routes/monitor.grid.tsx` — grid body scrolls inside; the sticky column header stays visible. - [ ] `routes/monitor.task.$taskId.tsx` — transcript area is the scrolling region; the action bar + metadata strip are pinned (will be revisited when #223 mockup lands, but don't block on it). - [ ] `routes/agents.tsx` — agent cards grid scrolls inside. - [ ] `routes/stats.tsx` — charts column scrolls; sidebar / header pinned. - [ ] `routes/usage.tsx` — breakdown scrolls; header with quota strip pinned. - [ ] `routes/specs.tsx` — file list + editor each scroll independently (two-pane layout pattern). - [ ] `routes/planner.board.tsx` — per-column scroll already exists for cards; verify the outer shell is 100vh-capped. ### Already correct - [ ] `routes/planner.index.tsx` already uses `h-[calc(100vh-64px)] min-h-0` — keep as reference pattern. Audit other routes against this. ### Small screens (< md) - [ ] Keep today's behaviour — content flows, body scrolls globally. Phones don't get the viewport-cap. Tailwind breakpoint: default `md: 768px`. ### Verification - [ ] Test matrix: - 360×640 (phone portrait) — global scroll, top nav stacks if it needs to. - 1280×720 (laptop) — 100vh, per-region scroll, no global scrollbar on `html`. - 1920×1080 (desktop) — same, more breathing room. - [ ] Playwright: extend `apps/web/e2e/monitor.spec.ts` with a 1280×720 viewport assertion that `document.documentElement.scrollHeight === document.documentElement.clientHeight` (no vertical overflow at the page level). - [ ] Manual smoke: scrolling inside a pipeline list with 40+ rows, the top nav and conn pill stay pinned. ## Out of scope - Task detail page redesign — covered by #223 Penpot mockup + #224 implementation. - Touch-device tweaks beyond the breakpoint switch (inertial scrolling, safe-area insets) — file a follow-up if needed. - Any visual restyle — purely layout + overflow. ## References - `apps/web/src/routes/planner.index.tsx:153` — the canonical pattern (`h-[calc(100vh-64px)] min-h-0`). - `apps/web/src/components/app-shell.tsx` — the shared shell to amend. - Tailwind `md:` breakpoint = 768 px.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
charles/claude-hooks#228
No description provided.