Skip to content

Commit 2bc4dc4

Browse files
author
Lailo
committed
adds icons to header drop down menu
1 parent 1859723 commit 2bc4dc4

File tree

2 files changed

+18
-14
lines changed

2 files changed

+18
-14
lines changed

src/components/layout/AppHeader.tsx

+8-10
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ import dynamic from 'next/dynamic'
55
import Dropdown from '@components/Dropdown'
66
import routes from '@utils/routes'
77
import { FiMoreHorizontal } from 'react-icons/fi'
8+
import { AiOutlineFontColors } from 'react-icons/ai'
9+
import { MdFeaturedPlayList } from 'react-icons/md'
810

911
const ThemeSwitch = dynamic(() => import('@components/layout/ThemeSwitch'), {
1012
ssr: false,
@@ -34,23 +36,19 @@ const AppHeader: React.FC<Props> = ({ className }) => {
3436
</div>
3537
<div>
3638
<Dropdown buttonLabel={<FiMoreHorizontal />}>
37-
<ul className="w-40 space-y-4 py-2">
39+
<ul className="w-40 space-y-4 py-2 text-sm">
3840
<li>
3941
<Link {...routes.COMPONENTS}>
40-
<a
41-
className="text-green-600 hover:underline"
42-
title="components"
43-
>
42+
<a className="text-primary hover:underline" title="components">
43+
<MdFeaturedPlayList className="inline mr-2" />
4444
Components
4545
</a>
4646
</Link>
4747
</li>
4848
<li>
4949
<Link {...routes.TYPOGRAPHY}>
50-
<a
51-
className="text-green-600 hover:underline"
52-
title="Typography"
53-
>
50+
<a className="text-primary hover:underline" title="Typography">
51+
<AiOutlineFontColors className="inline mr-2" />
5452
Typography
5553
</a>
5654
</Link>
@@ -59,7 +57,7 @@ const AppHeader: React.FC<Props> = ({ className }) => {
5957
<hr className="dark:border-gray-700" />
6058
</li>
6159
<li className="flex items-center justify-between">
62-
<span className="mr-auto text-sm text-gray-600">Theme</span>
60+
<span className="mr-auto text-gray-600">Theme</span>
6361
<ThemeSwitch />
6462
</li>
6563
</ul>

src/components/layout/__snapshots__/AppHeader.test.tsx.snap

+10-4
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,20 @@ exports[`AppHeader matches snapshot 1`] = `
2424
buttonLabel={<FiMoreHorizontal />}
2525
>
2626
<ul
27-
className="w-40 space-y-4 py-2"
27+
className="w-40 space-y-4 py-2 text-sm"
2828
>
2929
<li>
3030
<Link
3131
as="/components"
3232
href="/components"
3333
>
3434
<a
35-
className="text-green-600 hover:underline"
35+
className="text-primary hover:underline"
3636
title="components"
3737
>
38+
<MdFeaturedPlayList
39+
className="inline mr-2"
40+
/>
3841
Components
3942
</a>
4043
</Link>
@@ -45,9 +48,12 @@ exports[`AppHeader matches snapshot 1`] = `
4548
href="/typography"
4649
>
4750
<a
48-
className="text-green-600 hover:underline"
51+
className="text-primary hover:underline"
4952
title="Typography"
5053
>
54+
<AiOutlineFontColors
55+
className="inline mr-2"
56+
/>
5157
Typography
5258
</a>
5359
</Link>
@@ -61,7 +67,7 @@ exports[`AppHeader matches snapshot 1`] = `
6167
className="flex items-center justify-between"
6268
>
6369
<span
64-
className="mr-auto text-sm text-gray-600"
70+
className="mr-auto text-gray-600"
6571
>
6672
Theme
6773
</span>

0 commit comments

Comments
 (0)