diff --git a/src/app/products/page.tsx b/src/app/products/page.tsx new file mode 100644 index 0000000..de46bf8 --- /dev/null +++ b/src/app/products/page.tsx @@ -0,0 +1,209 @@ +"use client"; + +import NavbarLayoutFloatingInline from '@/components/navbar/NavbarLayoutFloatingInline'; +import FooterCard from '@/components/sections/footer/FooterCard'; +import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider"; +import { Mail, MapPin, Phone } from 'lucide-react'; +import { useState, useMemo } from 'react'; + +const CATEGORIES = [ + "Beer", "Craft Beer", "Wine", "Champagne", "Gin", "Vodka", "Rum", "Whisky", "Tequila", "Liqueurs", "RTDs", "Premixed Drinks", "Low Alcohol", "Mixers", "Specials"]; + +const SAMPLE_PRODUCTS = [ + { id: "1", name: "Corona Extra", category: "Beer", price: "$3.99", rating: 4.5, reviewCount: "256" }, + { id: "2", name: "Heineken Premium", category: "Beer", price: "$4.49", rating: 4.3, reviewCount: "189" }, + { id: "3", name: "Tuatara Pale Ale", category: "Craft Beer", price: "$7.99", rating: 4.8, reviewCount: "342" }, + { id: "4", name: "Hobbiton Brewing IPA", category: "Craft Beer", price: "$8.49", rating: 4.7, reviewCount: "218" }, + { id: "5", name: "Marlborough Sauvignon Blanc", category: "Wine", price: "$18.99", rating: 4.6, reviewCount: "512" }, + { id: "6", name: "Penfolds Shiraz", category: "Wine", price: "$22.99", rating: 4.5, reviewCount: "387" }, + { id: "7", name: "Champagne Moët", category: "Champagne", price: "$54.99", rating: 4.9, reviewCount: "421" }, + { id: "8", name: "Gordon's Gin", category: "Gin", price: "$29.99", rating: 4.4, reviewCount: "267" }, + { id: "9", name: "Tanqueray Gin", category: "Gin", price: "$32.99", rating: 4.5, reviewCount: "198" }, + { id: "10", name: "Vodka Smirnoff", category: "Vodka", price: "$24.99", rating: 4.2, reviewCount: "310" }, + { id: "11", name: "Bacardi Rum", category: "Rum", price: "$28.99", rating: 4.3, reviewCount: "276" }, + { id: "12", name: "Johnnie Walker Red", category: "Whisky", price: "$35.99", rating: 4.4, reviewCount: "445" }, + { id: "13", name: "Jack Daniel's", category: "Whisky", price: "$42.99", rating: 4.6, reviewCount: "678" }, + { id: "14", name: "José Cuervo Tequila", category: "Tequila", price: "$26.99", rating: 4.2, reviewCount: "156" }, + { id: "15", name: "Kahlúa Liqueur", category: "Liqueurs", price: "$19.99", rating: 4.5, reviewCount: "203" }, + { id: "16", name: "Baileys Irish Cream", category: "Liqueurs", price: "$22.99", rating: 4.7, reviewCount: "534" }, + { id: "17", name: "Pre-mixed Mojito", category: "RTDs", price: "$5.99", rating: 4.1, reviewCount: "89" }, + { id: "18", name: "Ready-made Margarita", category: "Premixed Drinks", price: "$6.49", rating: 4.2, reviewCount: "112" }, + { id: "19", name: "Skinny Lemonade", category: "Low Alcohol", price: "$4.99", rating: 4.3, reviewCount: "145" }, + { id: "20", name: "Fever-Tree Tonic", category: "Mixers", price: "$3.99", rating: 4.6, reviewCount: "267" }, +]; + +export default function ProductsPage() { + const [selectedCategory, setSelectedCategory] = useState("All"); + const [searchTerm, setSearchTerm] = useState(""); + + const filteredProducts = useMemo(() => { + return SAMPLE_PRODUCTS.filter(product => { + const matchesCategory = selectedCategory === "All" || product.category === selectedCategory; + const matchesSearch = product.name.toLowerCase().includes(searchTerm.toLowerCase()); + return matchesCategory && matchesSearch; + }); + }, [selectedCategory, searchTerm]); + + return ( + + + +
+
+ {/* Page Header */} +
+

+ Product Catalog +

+

+ Discover our complete selection of premium beverages +

+
+ + {/* Search Bar */} +
+ setSearchTerm(e.target.value)} + className="w-full px-4 py-3 rounded-lg bg-card border border-accent/20 text-foreground placeholder-foreground/50 focus:outline-none focus:border-accent" + /> +
+ + {/* Categories Filter */} +
+ + {CATEGORIES.map((category) => ( + + ))} +
+ + {/* Products Grid */} +
+ {filteredProducts.map((product) => ( +
+
+
+

Product Image

+

{product.category}

+
+
+
+

+ {product.category} +

+

+ {product.name} +

+
+ + {product.price} + +
+ + {product.rating} + + +
+
+

+ {product.reviewCount} reviews +

+ +
+
+ ))} +
+ + {/* No Results */} + {filteredProducts.length === 0 && ( +
+

+ No products found matching your search. +

+
+ )} + + {/* Results Count */} +
+

+ Showing {filteredProducts.length} of {SAMPLE_PRODUCTS.length} products +

+
+
+
+ + +
+ ); +}