fix: landing page user buttons

This commit is contained in:
Damien Ostler 2024-02-15 21:52:31 -05:00
parent 937faf1847
commit 9169063a08

View File

@ -11,7 +11,7 @@ import MenuItem from '@mui/material/MenuItem';
import Drawer from '@mui/material/Drawer'; import Drawer from '@mui/material/Drawer';
import MenuIcon from '@mui/icons-material/Menu'; import MenuIcon from '@mui/icons-material/Menu';
import ToggleColorMode from './ToggleColorMode'; import ToggleColorMode from './ToggleColorMode';
import { ArrowLeftOutlined, ArrowRightRounded, OpenInNew } from '@mui/icons-material'; import { ArrowLeftOutlined, ArrowRightRounded, Logout, OpenInNew } from '@mui/icons-material';
const logoStyle = { const logoStyle = {
width: '140px', width: '140px',
@ -139,16 +139,29 @@ function AppAppBar({ user }: AppAppBarProps) {
}} }}
> >
{(user ? ( {(user ? (
<Button <>
color="secondary" <Button color="primary">{user.nickname}</Button>
variant="contained" <Button
size="small" color="secondary"
component="a" variant="contained"
href="/api/auth/login" size="small"
startIcon={<OpenInNew />} component="a"
> href="/api/auth/login"
Dashboard startIcon={<OpenInNew />}
</Button> >
Dashboard
</Button>
<Button
color="error"
variant="outlined"
size="small"
component="a"
href="/api/auth/logout"
startIcon={<Logout />}
>
Logout
</Button>
</>
) : ( ) : (
<Box> <Box>
<Button <Button