Skip to content

Commit c2d61e0

Browse files
committed
Add tooltip and update profile icon
1 parent 55b6bd8 commit c2d61e0

File tree

1 file changed

+17
-13
lines changed

1 file changed

+17
-13
lines changed

src/components/NavBar.tsx

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React from 'react';
22
import Link from 'next/link';
33
import Image from 'next/image';
4-
import { IconButton } from '@mui/material';
4+
import { IconButton, Tooltip } from '@mui/material';
55

66
export default function NavBar() {
77
return (
@@ -10,26 +10,30 @@ export default function NavBar() {
1010
<Image
1111
src={'/background.png'}
1212
alt="background"
13-
className="-z-10"
13+
className="-z-10 object-cover"
1414
fill
1515
/>
16+
1617
<Link
1718
href="/"
1819
className="font-display flex items-center gap-2 text-lg font-medium md:text-xl md:font-bold"
1920
>
2021
UTD Notebook
2122
</Link>
22-
<div className="ml-auto flex gap-x-2 md:gap-x-4">
23-
<IconButton size="large" sx={{ p: 0 }}>
24-
<div className="relative size-16 flex-shrink-0">
25-
<Image
26-
src="/icon-white.svg"
27-
alt="profile picture"
28-
fill
29-
className="rounded-full border border-white object-cover"
30-
/>
31-
</div>
32-
</IconButton>
23+
24+
<div className="ml-auto flex items-center gap-x-2 md:gap-x-4">
25+
<Tooltip title="Profile">
26+
<IconButton size="medium" href="/profile">
27+
<div className="relative size-10 flex-shrink-0 md:size-12">
28+
<Image
29+
src="/icon-white.svg"
30+
alt="profile picture"
31+
fill
32+
className="rounded-full border-2 border-white object-cover"
33+
/>
34+
</div>
35+
</IconButton>
36+
</Tooltip>
3337
</div>
3438
</div>
3539
</>

0 commit comments

Comments
 (0)