Skip to content

fix(web): fix #1057 mobile navigation identity confirmation - #1165

Merged
vjuliaife merged 1 commit into
vjuliaife:mainfrom
Owolabenjade:fix/issue-1057-mobile-nav-user-email
Aug 27, 2026
Merged

fix(web): fix #1057 mobile navigation identity confirmation#1165
vjuliaife merged 1 commit into
vjuliaife:mainfrom
Owolabenjade:fix/issue-1057-mobile-nav-user-email

Conversation

@Owolabenjade

Copy link
Copy Markdown
Contributor

Close #1057

This PR addresses issue #1057 where the top navigation bar (apps/web/components/Nav.tsx) hid the logged-in user's email address on small/mobile viewports (< 640px) because the email <span> was styled with Tailwind utility classes hidden sm:inline.

On narrow viewports (such as mobile screens), the navigation bar rendered only a generic "Log out" button and the active role link ("Bond dashboard" or "Surety admin"). This created identity ambiguity and UX friction when users switched between different importer or surety demo accounts on mobile devices, as there was no visible indicator of which account was currently authenticated.

Solution & Flow

  • Modified apps/web/components/Nav.tsx to group the active role link and a mobile-specific user email element inside a column flexbox container (flex flex-col items-start leading-tight).
  • Added a mobile-only element <span className="text-[11px] text-muted sm:hidden max-w-[130px] truncate" title={user.email}>{user.email}</span> rendered directly beneath the role link.
  • Retained the existing desktop element <span className="hidden sm:inline text-muted">{user.email}</span> to preserve horizontal inline rendering on screens 640px (sm) and wider.

Value & Impact

This change resolves account switching confusion on mobile viewports for issue #1057 without introducing header clutter or altering desktop visual layout and responsive breakpoints.

Changed

Testing

The fix was verified using the following static analysis and build verification scripts:

# Verify TypeScript type definitions and component props
npm run typecheck --workspace=apps/web

# Verify zero ESLint warnings or code quality violations
npm run lint --workspace=apps/web

@drips-wave

drips-wave Bot commented Aug 27, 2026

Copy link
Copy Markdown

@Owolabenjade Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@vercel

vercel Bot commented Aug 27, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
tariff-shield-web Error Error Aug 27, 2026 5:28pm

@vercel

vercel Bot commented Aug 27, 2026

Copy link
Copy Markdown

Deployment failed for project tariff-shield-web with the following error:

The `vercel.json` schema validation failed with the following message: should NOT have additional property `rootDirectory`

Learn More: https://vercel.com/docs/concepts/projects/project-configuration

@vjuliaife
vjuliaife merged commit 5cba0c5 into vjuliaife:main Aug 27, 2026
9 of 26 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.

Nav hides the logged-in user's email on mobile with no alternative way to confirm identity

2 participants