Skip to content

Commit

Permalink
Fix Mobile Header (#247)
Browse files Browse the repository at this point in the history
  • Loading branch information
avgupta456 authored Nov 27, 2023
1 parent a51dbaa commit 1da63f5
Showing 1 changed file with 20 additions and 14 deletions.
34 changes: 20 additions & 14 deletions frontend/src/pages/App/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -154,17 +154,29 @@ const Header = ({ mode }) => {
</div>
{/* Hamburger Dropdown */}
<div className={classnames('p-5 pt-0', !toggle && 'hidden')}>
{isAuthenticated ? (
{mode === 'trends' && (
<>
<MobileLink to="/wrapped" onClick={() => setToggle(false)}>
<MobileLink to={WRAPPED_URL} onClick={() => setToggle(false)}>
Wrapped
</MobileLink>
<MobileLink to="/user" onClick={() => setToggle(false)}>
Dashboard
</MobileLink>
<MobileLink to="/settings" onClick={() => setToggle(false)}>
Settings
</MobileLink>
{isAuthenticated ? (
<MobileLink to="/user" onClick={() => setToggle(false)}>
Dashboard
</MobileLink>
) : (
<MobileLink to="/demo" onClick={() => setToggle(false)}>
Demo
</MobileLink>
)}
</>
)}
{isAuthenticated ? (
<>
{mode === 'trends' && (
<MobileLink to="/settings" onClick={() => setToggle(false)}>
Settings
</MobileLink>
)}
<MobileLink
to="/"
onClick={() => {
Expand All @@ -177,12 +189,6 @@ const Header = ({ mode }) => {
</>
) : (
<>
<MobileLink to="/wrapped" onClick={() => setToggle(false)}>
Wrapped
</MobileLink>
<MobileLink to="/demo" onClick={() => setToggle(false)}>
Demo
</MobileLink>
<a
className="block text-sm px-2 my-2 py-2 rounded-sm bg-gray-200 text-gray-700"
href={GITHUB_PUBLIC_AUTH_URL}
Expand Down

1 comment on commit 1da63f5

@vercel
Copy link

@vercel vercel bot commented on 1da63f5 Nov 27, 2023

Choose a reason for hiding this comment

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

Please sign in to comment.