-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1b7b8ba
commit 23649f7
Showing
2 changed files
with
37 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,37 @@ | ||
import Button from "./Button"; | ||
import { useState } from "react"; | ||
import { AiOutlineClose, AiOutlineMenu } from "react-icons/ai"; | ||
export default function Hamburger(){ | ||
return( | ||
<div className="z-[150] w-[85%] min-h-[144px] flex items-center justify-end font-roboto mr-0 md:ml-4 md:ml-0 fixed top-0 left-0"> | ||
<div className="rounded-full bg-black flex items-center justify-center px-4 py-4"> <AiOutlineMenu size={20} className="text-[#FFFFFF]" /> </div> | ||
</div> | ||
) | ||
} | ||
import Love from "./Love"; | ||
|
||
export default function Hamburger() { | ||
const [nav, setNav] = useState(false); | ||
const navItems = ["About us", "Board of Love", "Plugins", "Contact Us"]; | ||
|
||
return ( | ||
<div className="z-[150] w-[90%] md:w-[95%] min-h-[144px] flex items-center justify-end font-roboto mr-0 md:ml-4 md:ml-0 fixed top-0 left-0"> | ||
<div onClick={() => setNav(!nav)} className="rounded-full bg-purple-600 flex items-center justify-center px-4 py-4"> | ||
{nav ? <AiOutlineClose size={20} /> : <AiOutlineMenu size={20} />} | ||
</div> | ||
<ul | ||
className={ | ||
nav | ||
? "fixed left-0 top-0 w-[60%] md:w-[30%] h-full border-r text-white border-r-gray-900 bg-[#28143a] ease-in-out duration-500 z-50" | ||
: "ease-in-out w-[60%] duration-500 fixed top-0 bottom-0 left-[-100%]" | ||
} | ||
> | ||
<li className="p-4"> | ||
{/* You haven't defined Love component, assuming it's already imported */} | ||
<Love /> | ||
</li> | ||
{/* Mobile Navigation Items */} | ||
{navItems.map((item) => ( | ||
<li | ||
key={item} | ||
className="p-4 border-b rounded-xl hover:bg-[#cccccc] hover:text-black duration-300 cursor-pointer border-gray-600" | ||
> | ||
{item} | ||
</li> | ||
))} | ||
</ul> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -55,4 +55,4 @@ export default function Home() { | |
</div> | ||
</> | ||
) | ||
} | ||
} |