Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Navbar mobile refactored design #1568

Merged
merged 7 commits into from
Jun 21, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
added x's for open menus
  • Loading branch information
mertbagt committed Jun 7, 2024
commit 2d40fbf3fc38f3a1b307d3c8d7108bf69635e3ca
24 changes: 18 additions & 6 deletions components/MobileNavV2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import {
} from "./NavbarComponents"

import { Col, Row } from "./bootstrap"
import Image from "react-bootstrap/Image"

const NavBarBoxContainer: FC<
React.PropsWithChildren<{ className?: string }>
Expand Down Expand Up @@ -130,11 +131,18 @@ export const MobileNavV2: React.FC<React.PropsWithChildren<unknown>> = () => {
>
<Container>
<Col>
<Navbar.Brand href="#home">
<Navbar.Toggle
aria-controls="basic-navbar-nav"
onClick={toggleSite}
/>
<Navbar.Brand onClick={toggleSite}>
{isExpanded && whichMenu == "site" ? (
<Image
src="/Union.svg"
alt="x"
width="35"
height="35"
className="ms-2"
/>
) : (
<Navbar.Toggle aria-controls="basic-navbar-nav" />
)}
</Navbar.Brand>
</Col>
<Col>
Expand All @@ -147,7 +155,11 @@ export const MobileNavV2: React.FC<React.PropsWithChildren<unknown>> = () => {
<>
<Navbar.Brand onClick={toggleAvatar}>
<Nav.Link className="p-0 text-white">
<Avatar isOrg={isOrg} />
{isExpanded && whichMenu == "profile" ? (
<Image src="/Union.svg" alt="x" width="35" height="35" />
) : (
<Avatar isOrg={isOrg} />
)}
</Nav.Link>
</Navbar.Brand>
</>
Expand Down
3 changes: 3 additions & 0 deletions public/Union.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading