Bob AI: Add menu-order page

This commit is contained in:
kudinDmitriyUp
2026-06-02 17:36:09 +00:00
parent 7c0ed5f5ce
commit 21e3d9110b
4 changed files with 118 additions and 1 deletions

View File

@@ -2,11 +2,13 @@ import { Routes, Route } from 'react-router-dom';
import Layout from './components/Layout';
import HomePage from './pages/HomePage';
import MenuOrderPage from "@/pages/MenuOrderPage";
export default function App() {
return (
<Routes>
<Route element={<Layout />}>
<Route path="/" element={<HomePage />} />
<Route path="/menu-order" element={<MenuOrderPage />} />
</Route>
</Routes>
);

View File

@@ -34,7 +34,9 @@ export default function Layout() {
{
"name": "Social Proof",
"href": "#social-proof"
}
},
{ name: "Menu Order", href: "/menu-order" },
];
return (

112
src/pages/MenuOrderPage.tsx Normal file
View File

@@ -0,0 +1,112 @@
import { routes } from "@/routes";
import NavbarCentered from "@/components/ui/NavbarCentered";
import HeroBillboard from "@/components/sections/hero/HeroBillboard";
import ProductQuantityCards from "@/components/sections/product/ProductQuantityCards";
import FooterSimple from "@/components/sections/footer/FooterSimple";
const MenuOrderPage = () => {
const handleAddToCart = (productName: string, quantity: number) => {
console.log(`Added ${quantity} of ${productName} to cart.`);
alert(`Added ${quantity} of ${productName} to your order!`);
};
return (
<div className="flex flex-col min-h-screen bg-background text-foreground">
<NavbarCentered
logo="Foodie"
navItems={routes.map((r) => ({ name: r.label, href: r.path }))}
ctaButton={{ text: "Order Now", href: "/menu-order" }}
/>
<main className="flex-grow">
<HeroBillboard
tag="Our Menu"
title="Delicious Meals, Delivered Fast"
description="Explore our wide selection of dishes, from appetizers to desserts. Freshly prepared and ready for your enjoyment."
primaryButton={{ text: "View All Items", href: "#menu-items" }}
secondaryButton={{ text: "Contact Us", href: "/contact" }}
imageSrc="https://img.b2bpic.net/img/food-delivery.webp"
/>
<ProductQuantityCards
tag="Order Online"
title="Browse Our Specialties"
description="Select your favorite dishes and customize your order. Fast and easy checkout."
products={[
{
name: "Classic Burger",
price: "$12.99",
imageSrc: "https://img.b2bpic.net/img/burger.webp",
onAddToCart: (quantity) => handleAddToCart("Classic Burger", quantity),
},
{
name: "Margherita Pizza",
price: "$15.50",
imageSrc: "https://img.b2bpic.net/img/pizza.webp",
onAddToCart: (quantity) => handleAddToCart("Margherita Pizza", quantity),
},
{
name: "Caesar Salad",
price: "$9.75",
imageSrc: "https://img.b2bpic.net/img/salad.webp",
onAddToCart: (quantity) => handleAddToCart("Caesar Salad", quantity),
},
{
name: "Spaghetti Carbonara",
price: "$14.00",
imageSrc: "https://img.b2bpic.net/img/pasta.webp",
onAddToCart: (quantity) => handleAddToCart("Spaghetti Carbonara", quantity),
},
{
name: "Sushi Platter",
price: "$22.00",
imageSrc: "https://img.b2bpic.net/img/sushi.webp",
onAddToCart: (quantity) => handleAddToCart("Sushi Platter", quantity),
},
{
name: "Chocolate Lava Cake",
price: "$7.50",
imageSrc: "https://img.b2bpic.net/img/dessert.webp",
onAddToCart: (quantity) => handleAddToCart("Chocolate Lava Cake", quantity),
},
]}
/>
</main>
<FooterSimple
brand="Foodie"
columns={[
{
title: "Company",
items: [
{ label: "About Us", href: "/about" },
{ label: "Careers", href: "#" },
{ label: "Blog", href: "/blog" },
],
},
{
title: "Support",
items: [
{ label: "Contact", href: "/contact" },
{ label: "FAQ", href: "/faq" },
],
},
{
title: "Legal",
items: [
{ label: "Privacy Policy", href: "/privacy" },
{ label: "Terms of Service", href: "/terms" },
],
},
]}
copyright="© 2024 Foodie. All rights reserved."
links={[
{ label: "Privacy", href: "/privacy" },
{ label: "Terms", href: "/terms" },
]}
/>
</div>
);
};
export default MenuOrderPage;

View File

@@ -6,4 +6,5 @@ export interface Route {
export const routes: Route[] = [
{ path: '/', label: 'Home', pageFile: 'HomePage' },
{ path: '/menu-order', label: 'Menu Order', pageFile: 'MenuOrderPage' },
];