menu update
This commit is contained in:
parent
2da1dfcfde
commit
3c46ff58e6
9
Websites/jefes-nextjs/app/Bar/page.tsx
Normal file
9
Websites/jefes-nextjs/app/Bar/page.tsx
Normal file
@ -0,0 +1,9 @@
|
||||
import React from 'react'
|
||||
|
||||
const page = () => {
|
||||
return (
|
||||
<div>page</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default page
|
||||
@ -1,4 +1,6 @@
|
||||
import React from 'react'
|
||||
import Link from 'next/link'
|
||||
import MenuLinks from './MenuLinks'
|
||||
|
||||
const MenuBar = () => {
|
||||
return (
|
||||
|
||||
@ -1,24 +1,44 @@
|
||||
"use client";
|
||||
|
||||
import React from 'react'
|
||||
import clsx from 'clsx';
|
||||
import Link from 'next/link';
|
||||
import { usePathname } from 'next/navigation';
|
||||
import React from "react";
|
||||
import clsx from "clsx";
|
||||
import Link from "next/link";
|
||||
import { usePathname } from "next/navigation";
|
||||
|
||||
const links = [
|
||||
{name: 'Appetizers', href: '/menu'},
|
||||
{name: 'Brunch', href: '/menu/brunch'},
|
||||
{name: 'Lunch', href: '/menu/lunch'},
|
||||
{name: 'Dinner', href: '/menu/dinner'},
|
||||
{name: 'Beverages', href: '/menu/beverages'},
|
||||
{name: 'Beverages', href: '/menu/beverages'},
|
||||
|
||||
]
|
||||
{ name: "Appetizers", href: "/menu" },
|
||||
{ name: "Brunch", href: "/menu/Brunch" },
|
||||
{ name: "Lunch", href: "/menu/Lunch" },
|
||||
{ name: "Dinner", href: "/menu/Dinner" },
|
||||
{ name: "Beverages", href: "/menu/Beverages" },
|
||||
{ name: "Bar", href: "/menu/Bar" },
|
||||
];
|
||||
|
||||
const MenuLinks = () => {
|
||||
return (
|
||||
<div>MenuLinks</div>
|
||||
)
|
||||
}
|
||||
const pathname = usePathname();
|
||||
|
||||
export default MenuLinks
|
||||
return (
|
||||
<>
|
||||
{links.map((link) => {
|
||||
// const LinkIcon = link.icon;
|
||||
return (
|
||||
<Link
|
||||
key={link.name}
|
||||
href={link.href}
|
||||
className={clsx(
|
||||
"flex h-[48px] grow items-center justify-center gap-2 bg-transparent p-3 text-xl font-semibold hover:text-red-700 md:flex-none md:justify-start md:p-2 md:px-3",
|
||||
{
|
||||
"text-red-700": pathname === link.href,
|
||||
}
|
||||
)}
|
||||
>
|
||||
{/* <LinkIcon className="w-6" /> */}
|
||||
<p className="hidden md:block">{link.name}</p>
|
||||
</Link>
|
||||
);
|
||||
})}
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
export default MenuLinks;
|
||||
|
||||
@ -2,7 +2,7 @@ import React from 'react'
|
||||
|
||||
const page = () => {
|
||||
return (
|
||||
<div>page</div>
|
||||
<div>Beverages</div>
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@ import React from 'react'
|
||||
|
||||
const page = () => {
|
||||
return (
|
||||
<div>page</div>
|
||||
<div>Brunch</div>
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
import React from "react";
|
||||
import Image from "next/image";
|
||||
import MenuLinks from "../components/MenuBar/MenuLinks";
|
||||
|
||||
const layout = ({ children }: { children: React.ReactNode }) => {
|
||||
return (
|
||||
@ -22,8 +23,10 @@ const layout = ({ children }: { children: React.ReactNode }) => {
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="flex-grow p-6 md:overflow-y-auto md:p-12 bg-paintbg">{children}</div>
|
||||
<div className="flex flex-row justify-evenly pt-4">
|
||||
<MenuLinks />
|
||||
</div>
|
||||
<div className="flex-grow p-6 md:overflow-y-auto md:p-12">{children}</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
@ -5,9 +5,7 @@ import Image from "next/image";
|
||||
const menu = () => {
|
||||
return (
|
||||
<div className="flex flex-col relative justify-center items-center ">
|
||||
<div>
|
||||
<Appetizers />
|
||||
</div>
|
||||
<Appetizers />
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
Loading…
Reference in New Issue
Block a user