Skip to content

fix(ui): fix responsive header navigation on smaller screens#1300

Open
opspawn wants to merge 2 commits intokagent-dev:mainfrom
opspawn:fix/responsive-header-nav
Open

fix(ui): fix responsive header navigation on smaller screens#1300
opspawn wants to merge 2 commits intokagent-dev:mainfrom
opspawn:fix/responsive-header-nav

Conversation

@opspawn
Copy link
Contributor

@opspawn opspawn commented Feb 14, 2026

Summary

Raised the desktop/mobile navigation breakpoint from md (768px) to lg (1024px) in the Header component.

At the md breakpoint, the desktop navigation items (Home, Create, View, Contribute, Community, Theme Toggle) were too cramped and overlapped on tablet-sized screens (768px-1023px). The mobile hamburger menu now covers this range, providing a clean layout at all viewport widths.

Changes

Only ui/src/components/Header.tsx is modified - 5 Tailwind class changes:

Element Before After
<nav> padding md:py-8 lg:py-8
Container padding md:px-6 lg:px-6
Mobile menu button md:hidden lg:hidden
Desktop nav hidden md:flex space-x-2 lg:space-x-4 hidden lg:flex space-x-4
Mobile menu panel md:hidden lg:hidden

Test plan

  • Verified at 375px (mobile phone) - hamburger menu
  • Verified at 768px (tablet) - hamburger menu (was broken desktop nav before)
  • Verified at 850px - hamburger menu (was cramped before)
  • Verified at 1023px - hamburger menu
  • Verified at 1024px - desktop navigation with comfortable spacing
  • Verified at 1280px - desktop navigation (unchanged)
  • Verified mobile menu opens/closes correctly with all items accessible

Fixes #323

Signed-off-by: opspawn opspawnhq@gmail.com

Raise the desktop/mobile navigation breakpoint from md (768px) to lg
(1024px). At the md breakpoint the desktop navigation items were too
cramped and overlapped on tablet-sized screens (768px-1023px). The
mobile hamburger menu now covers this range, providing a clean layout
at all viewport widths.

Fixes kagent-dev#323

Signed-off-by: OpSpawn <opspawn@users.noreply.github.com>
Copilot AI review requested due to automatic review settings February 14, 2026 14:29
@opspawn opspawn requested a review from peterj as a code owner February 14, 2026 14:29
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adjusts the Header’s responsive breakpoints so tablet-sized viewports (768px–1023px) use the mobile hamburger menu instead of the cramped desktop navigation, resolving the overlap issue reported in #323.

Changes:

  • Shifted Header layout breakpoint from md to lg for vertical/horizontal padding.
  • Updated visibility breakpoints for the hamburger button, desktop nav container, and mobile menu panel to use lg.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

{/* Mobile menu button */}
<button
className="md:hidden p-2 focus:outline-none"
className="lg:hidden p-2 focus:outline-none"
Copy link

Copilot AI Feb 14, 2026

Choose a reason for hiding this comment

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

The mobile menu toggle button removes the browser focus outline (focus:outline-none) but doesn’t add any replacement focus-visible styling (e.g., ring/outline). This makes keyboard focus hard to see and is an accessibility regression for keyboard users. Consider adding a focus-visible ring/outline (consistent with other UI controls) instead of fully disabling focus styles.

Suggested change
className="lg:hidden p-2 focus:outline-none"
className="lg:hidden p-2 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-primary"

Copilot uses AI. Check for mistakes.
Addresses Copilot review feedback: replace focus:outline-none with
focus-visible ring styling so keyboard users can see focus state on
the hamburger button.

Signed-off-by: opspawn <agent@opspawn.com>
Signed-off-by: OpSpawn <opspawn@users.noreply.github.com>
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.

[BUG] Fix the navigation in header on smaller screens

1 participant