Skip to content

Fix mobile layout: stacked nav, scrollable tabs, table scroll wrappers - #61

Merged
jrodal98 merged 1 commit into
masterfrom
fix/mobile-responsive
Oct 21, 2026
Merged

jrodal98 merged 1 commit into
masterfrom
fix/mobile-responsive

Conversation

@jrodal98

Copy link
Copy Markdown
Owner

The viewport meta added in #59 exposed that the CSS had no responsive rules at all (zero @media queries): at phone width the nav wrapped into a staggered mess, the manage tab bar overflowed off-screen, and wide tables pushed the whole page sideways.

Measured at a 393px viewport (Playwright, logged-in admin), page width before -> after:

  • /manage (Create tab): 544px -> 393px
  • /manage (My Bookmarks): 919px -> 393px
  • /settings: 429px -> 393px (API token table)
  • /admin: 499px -> 393px (user table)
  • /help and /: already fit, unchanged
    Desktop (1280px) verified unchanged.

Changes:

  • main.css: .table-scroll wrapper (tables keep a 720px min width and scroll horizontally inside it instead of squeezing); @media (max-width: 768px) stacks the nav into centered wrapping rows, tightens container/cell padding, and lets long inline code samples wrap.
  • manage.css: tab bar scrolls horizontally on small screens instead of overflowing.
  • Templates: tables wrapped in .table-scroll (manage x2, admin, help x2, API token list, nested list; the nested table also drops its inline width style). The HTMX OOB-swapped personal-bookmarks table is wrapped at its include site, so swaps are unaffected.
  • tests/responsive_test.rs: guards the media queries, the .table-scroll CSS, and the wrappers on /manage, /help, /admin.

Verified: full cargo test suite green, plus Playwright screenshots at 393x852 (all pages fit, nav/tabs/tables clean) and 1280px desktop (no regression). Screenshots were taken against a locally seeded server; seed data included deliberately long URLs/descriptions to stress wrapping.

@jrodal98
jrodal98 merged commit 1e028d1 into master Oct 21, 2026
2 checks passed
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