|
1 | 1 | import Navbar from "@/components/Navbar"; |
2 | | -import Link from "next/link"; |
| 2 | +import StatesOfMatterGameCard from "@/components/StatesOfMatterGameCard"; |
| 3 | +import { Box, Flex, Heading, Text, SimpleGrid } from "@chakra-ui/react"; |
3 | 4 |
|
4 | 5 | export default function StatesOfMatterPage() { |
| 6 | + const games = [ |
| 7 | + { |
| 8 | + title: "Wire Spark", |
| 9 | + description: "Master the circuits and light up the city!", |
| 10 | + href: "/wireGame", |
| 11 | + bgGradient: "linear(to-br, blue.400, blue.600)", |
| 12 | + iconSrc: "/icons/wire-icon.svg", |
| 13 | + }, |
| 14 | + { |
| 15 | + title: "Heating Station", |
| 16 | + description: "Cook up some science in the heat lab!", |
| 17 | + href: "/cookingGame", |
| 18 | + bgGradient: "linear(to-br, orange.400, red.500)", |
| 19 | + iconSrc: "/icons/heat-icon.svg", |
| 20 | + }, |
| 21 | + { |
| 22 | + title: "Pipe Flow", |
| 23 | + description: "Connect the flow and fix the leaks!", |
| 24 | + href: "/pipesGame", |
| 25 | + bgGradient: "linear(to-br, teal.400, teal.500)", |
| 26 | + iconSrc: "/icons/pipe-icon.svg", |
| 27 | + }, |
| 28 | + ]; |
| 29 | + |
5 | 30 | return ( |
6 | | - <main> |
| 31 | + <Box minH="100vh" bg="#F4F8FB"> |
7 | 32 | <Navbar /> |
8 | 33 |
|
9 | | - {/* TODO: Implement the Figma Design here */} |
10 | | - <div className="flex flex-col items-center justify-center p-24"> |
11 | | - <h1 className="text-4xl font-bold mb-8">Choose a Game</h1> |
| 34 | + <Flex direction="column" align="center" pt={16} px={4}> |
| 35 | + {/* Main Title: Bumped to 5xl for maximum impact */} |
| 36 | + <Heading as="h1" size={{ base: "3xl", md: "5xl" }} color="gray.900" mb={4} fontWeight="900" textAlign="center"> |
| 37 | + Choose Your Experiment |
| 38 | + </Heading> |
| 39 | + |
| 40 | + <Text color="gray.500" fontSize="xl" fontWeight="medium" mb={16} textAlign="center"> |
| 41 | + Ready to become a scientist today? |
| 42 | + </Text> |
12 | 43 |
|
13 | | - {/* Placeholder links to verify your routing works */} |
14 | | - <div className="flex gap-4"> |
15 | | - <Link href="/wireGame" className="px-4 py-2 bg-blue-500 text-white rounded"> |
16 | | - Wire Game |
17 | | - </Link> |
18 | | - <Link href="/cookingGame" className="px-4 py-2 bg-blue-500 text-white rounded"> |
19 | | - Cooking Game |
20 | | - </Link> |
21 | | - <Link href="/pipesGame" className="px-4 py-2 bg-blue-500 text-white rounded"> |
22 | | - Pipes Game |
23 | | - </Link> |
24 | | - </div> |
25 | | - </div> |
26 | | - </main> |
| 44 | + <SimpleGrid columns={{ base: 1, md: 3 }} gap={10} maxW="6xl" w="full" px={4}> |
| 45 | + {games.map((game, index) => ( |
| 46 | + <StatesOfMatterGameCard key={index} {...game} /> |
| 47 | + ))} |
| 48 | + </SimpleGrid> |
| 49 | + </Flex> |
| 50 | + </Box> |
27 | 51 | ); |
28 | 52 | } |
0 commit comments