-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathMobileNavigation.js
More file actions
48 lines (46 loc) · 1.31 KB
/
MobileNavigation.js
File metadata and controls
48 lines (46 loc) · 1.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
import { Dropdown, DropdownItem, Button, MacPawLogo } from "../../src/ui";
import styles from "./mobileNavigation.module.css";
import Link from "next/link";
import { pages } from "../config/pages";
import ActiveLink from "../ActiveLink/ActiveLink";
const MobileNavigation = () => {
return (
<div className={styles.container}>
<div className={styles.logo}>
<Link href="/">
<MacPawLogo />
</Link>
</div>
<Dropdown
trigger={
<Button icon color="transparent">
<img src="/menu.svg" width={25} height={25} alt="Menu Icon" />
</Button>
}
position="right"
className={styles.dropdown}
>
<DropdownItem
component={ActiveLink}
href="/docs"
className={styles.navigationLink}
activeClassName={styles.activeLink}
>
Installation
</DropdownItem>
{[...pages].sort().map((link) => (
<DropdownItem
key={link}
component={ActiveLink}
href={`/docs/${link}`}
className={styles.navigationLink}
activeClassName={styles.activeLink}
>
{link.replaceAll("-", " ")}
</DropdownItem>
))}
</Dropdown>
</div>
);
};
export default MobileNavigation;