Merge pull request 'solved the sheet issue' (#4) from fahim-dev into main

Reviewed-on: https://git.planpostai.com/planpostai/planpost-landing-v2/pulls/4
This commit is contained in:
smfahim25 2025-03-03 08:51:09 +00:00
commit a6f050dffb

View file

@ -3,8 +3,15 @@ import Link from "next/link";
import Image from "next/image";
import { Menu } from "lucide-react";
import { Sheet, SheetContent, SheetTitle, SheetTrigger } from "./ui/sheet";
import { useState } from "react";
export default function Header() {
const [isOpen, setIsOpen] = useState(false);
const handleClose = () => {
setIsOpen(false);
};
return (
<nav className="flex items-center justify-between pr-4 absolute z-50 w-full">
<Link href="/">
@ -56,7 +63,7 @@ export default function Header() {
{/* Mobile Menu with Sheet Component */}
<div className="md:hidden">
<Sheet>
<Sheet open={isOpen} onOpenChange={setIsOpen}>
<SheetTrigger asChild>
<button className="text-gray-800 focus:outline-none mt-2">
<Menu className="w-8 h-8" />
@ -80,7 +87,11 @@ export default function Header() {
</div>
<ul className="flex flex-col space-y-6 text-gray-800 font-medium">
<li>
<Link href="/" className="hover:text-purple-600 text-lg">
<Link
href="/"
className="hover:text-purple-600 text-lg"
onClick={handleClose}
>
Home
</Link>
</li>
@ -88,6 +99,7 @@ export default function Header() {
<Link
href="/#feature"
className="hover:text-purple-600 text-lg"
onClick={handleClose}
>
Feature
</Link>
@ -96,6 +108,7 @@ export default function Header() {
<Link
href="/#pricingSection"
className="hover:text-purple-600 text-lg"
onClick={handleClose}
>
Pricing
</Link>
@ -104,6 +117,7 @@ export default function Header() {
<Link
href="/contact"
className="hover:text-purple-600 text-lg"
onClick={handleClose}
>
Contact
</Link>
@ -116,6 +130,7 @@ export default function Header() {
<Link
href="https://dashboard.planpostai.com/"
className="w-full"
onClick={handleClose}
>
<button className="w-full font-bold px-5 py-3 border-[1px] border-[#6A47ED] text-[#6A47ED] rounded-xl hover:bg-purple-100">
Log in
@ -124,6 +139,7 @@ export default function Header() {
<Link
href="https://dashboard.planpostai.com/"
className="w-full"
onClick={handleClose}
>
<button className="w-full font-bold px-5 py-3 bg-[#6A47ED] text-white rounded-xl hover:bg-purple-700">
Sign Up