Files
Web-Frontend/client/src/components/Header/Header.jsx
T

37 lines
1.1 KiB
React
Raw Normal View History

2026-06-04 15:30:01 -07:00
import { useRecipe, Button, Stack, Text, Flex } from "@chakra-ui/react"
import UserAvatarMenu from "./UserAvatarMenu.jsx";
2026-06-04 15:30:01 -07:00
import { useNavigate } from "react-router-dom";
import { NavLink } from "react-router-dom";
//TODO: Dynamically populate per each user
const user = {
name: "venessa kuchenik",
email: "vkuchenik@contractor.usgs.gov",
// avatar: "src\\assets\\user_profile.svg"
}
2026-06-04 15:30:01 -07:00
export default function Header() {
const navigate = useNavigate();
const recipe = useRecipe({ key: "header" });
const styles = recipe();
return (
2026-06-04 15:30:01 -07:00
<Flex css={styles}>
<Button as={NavLink} to={"/home"} color="color" variant="plain" textStyle="5xl" fontWeight="bold">
VDAP
</Button>
<Flex align="center" gap={3} pr={6}>
2025-07-30 08:34:07 -07:00
<Stack gap="0" textAlign="center" cursor="default">
<Text color="color" fontWeight="bold" textStyle="lg">{user.name}</Text>
<Text color="fg.muted" textStyle="sm">{user.email}</Text>
</Stack>
<UserAvatarMenu
name={user.name}
avatar={user.avatar}
/>
</Flex>
2026-06-04 15:30:01 -07:00
</Flex>
);
}