diff --git a/app/search/components/SearchSideBar.tsx b/app/search/components/SearchSideBar.tsx index fe749ad..892c0dc 100644 --- a/app/search/components/SearchSideBar.tsx +++ b/app/search/components/SearchSideBar.tsx @@ -1,33 +1,80 @@ -export default function SearchSideBar() { +import { Cuisine, Location, PRICE } from "@prisma/client"; +import Link from "next/link"; + +export default async function SearchSideBar({ + locations, + cuisines, + searchParams +}: { + locations: Location[]; + cuisines: Cuisine[]; + searchParams: {city?: string, location?: string, cuisine?: string, price: PRICE} +}) { + console.log("cuisines: ", cuisines); + console.log("locations: ", locations); + + const priceStyle = "border w-full text-reg font-light p-2 text-center" + const prices = [ + {label: "$", price: PRICE.CHEAP, className: `${priceStyle} rounded-l`}, + {label: "$$", price: PRICE.REGULAR, className: `${priceStyle} `}, + {label: "$$$", price: PRICE.EXPENSIVE, className: `${priceStyle} rounded-r`} + ]; + return (
Toronto
-Ottawa
-Montreal
-Hamilton
-Kingston
-Niagara
+ {locations.map((location, index) => ( + + {location.name} + + ))}Mexican
-Italian
-Chinese
+ {cuisines.map((cuisine, index) => ( + + {cuisine.name} + + ))}