Skip to content

feat(ui): show all problems and simplify theme control - #110

Merged
cameroncuster merged 1 commit into
mainfrom
cameroncuster/show-all-problems
Jul 26, 2026
Merged

feat(ui): show all problems and simplify theme control#110
cameroncuster merged 1 commit into
mainfrom
cameroncuster/show-all-problems

Conversation

@cameroncuster

Copy link
Copy Markdown
Owner

Summary

  • render the complete problem catalog immediately and remove pagination controls and helpers
  • replace the prominent Appearance picker with a secondary icon-only System → Light → Dark cycle
  • preserve signed-in Supabase persistence, anonymous local persistence, OS-following System mode, and 44px touch targets
  • update real-page and deterministic performance budgets for the 280-row homepage

Validation

  • pnpm run lint
  • pnpm run lint:es
  • pnpm run check
  • pnpm run test:coverage — 394 passed; 98.69% lines / 95.00% branches / 98.33% functions
  • pnpm run test:performance — 280 rows; 117,821 B raw / 5,666 B gzip
  • mocked desktop Playwright — 101 passed, 5 intentional skips
  • mocked mobile Playwright — 104 passed, 2 intentional skips

Risk

  • Homepage SSR and DOM are intentionally larger because all 280 problems now render immediately; explicit budgets guard this contract.
  • Theme selection remains optimistic locally. Signed-in persistence failures retain the retry action and do not alter another account's preference.

Pull Request opened by Augment Code | View session

@vercel

vercel Bot commented Jul 26, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
gitgud Ready Ready Preview, Comment Jul 26, 2026 6:05am

@cameroncuster
cameroncuster marked this pull request as ready for review July 26, 2026 06:05
@cameroncuster

cameroncuster commented Jul 26, 2026

Copy link
Copy Markdown
Owner Author

PR Risk Analyzer Agent🛡️

👀 Human Input Needed
A pair-review briefing is ready for you.

→ Pair Review Briefing

@cameroncuster
cameroncuster merged commit 60657df into main Jul 26, 2026
14 checks passed
@cameroncuster
cameroncuster deleted the cameroncuster/show-all-problems branch July 26, 2026 06:07

@cameroncuster cameroncuster left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deep Code Review Agent🐛

Review completed with 0 suggestions.

@cameroncuster

Copy link
Copy Markdown
Owner Author

Verifier 🛰️

🛰️ Verifier Report

TL;DR: Built and served the PR head against a local mock backend and drove the full-catalog homepage and the new icon-only theme cycle end-to-end in a real browser, on desktop and mobile.

🔍 Walkthrough

  • Homepage now renders the entire 280-problem catalog in one shot with zero pagination controls — on mainline it batched to 50 rows behind a "show more" affordance; on the head all 280 #problem-table-body rows are present and no more problems / Load more button exists. Confirmed by the hermetic suite (homepage renders every derived row without pagination or a hydration refetch, desktop + mobile) and re-driven live in a browser.

    live DOM readout against the served head (large fixture, 280 problems)
    { rows: 280, pagerButtons: [], firstLink: "Large Fixture Problem 1" }
    

    A single server-side problems read served the page (problemsReadCount incremented once; select id,name,difficulty,url,added_by,added_by_url,likes,dislikes,type) — no client-side hydration refetch.

    full 280-row catalog, dark theme, icon-only theme control in header homepage top, System theme
  • The Appearance radio picker is replaced by a single secondary icon button that cycles System → Light → Dark → System, updating data-theme, persisting to localStorage, and wrapping back to System — with the old role=radio picker gone (0 radios).

    each click, read live from the served head
    System → click → Theme: Light. Switch to Dark   | data-theme=light  | gitgud-theme=light
    Light  → click → Theme: Dark. Switch to System  | data-theme=dark   | gitgud-theme=dark
    Dark   → click → Theme: System. Switch to Light | data-theme=light* | gitgud-theme=system   (*System resolves to OS preference)
    legacyRadioPickers: 0
    

    Anonymous persistence via localStorage verified at each step; signed-in Supabase persistence + retry-on-failure covered by the hermetic suite. 0 console errors across the whole session.

  • Before → after theme, same page (light vs dark), showing the icon-only control in the header:
    light theme, sun icon control dark theme, moon icon control

  • On mobile the theme control stays secondary inside the menu and keeps a 44×44px touch target (icon-only, empty text) — measured live at 44×44, and the whole 280-row catalog still renders below the menu.
    mobile menu with secondary theme icon and full catalog below

  • The 280-row homepage stays within the updated performance budgetscheck:performance on the head reports the homepage HTML fixture at 280 rows / 117,821 B raw / 5,666 B gzip and passes (mainline capped this at 50 rows / smaller byte budgets).

📋 Scope

Under test: Remove homepage pagination/row-batching so all problems render immediately, and replace the Appearance radio picker with a secondary icon-only System→Light→Dark cycle button, preserving persistence, OS-following System mode, and 44px touch targets.

Not tested:

  • Signed-in Supabase theme persistence + retry-on-save-failure — covered by the hermetic Playwright suite (all 205 mocked specs pass, desktop + mobile), not separately re-driven live.
  • Live Supabase behavior (SUPABASE_SMOKE=1) — opt-in/read-only, out of scope unless requested.
  • Deleted pagination unit module (problem-pagination.test.ts) — covered by CI, not re-run here.

📦 Artifacts · homepage/System · light · dark · mobile


Don't like what you see? Add a verification skill so the next run tests this kind of change.

Want another run? Comment cosmos verify on this PR.

👍 / 👎 · View session

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant