diff --git a/client/public/godot.png b/client/public/godot.png new file mode 100644 index 0000000..863dadf Binary files /dev/null and b/client/public/godot.png differ diff --git a/client/public/landing_placeholder.png b/client/public/landing_placeholder.png new file mode 100644 index 0000000..5ebe541 Binary files /dev/null and b/client/public/landing_placeholder.png differ diff --git a/client/public/trophy.png b/client/public/trophy.png new file mode 100644 index 0000000..eb77989 Binary files /dev/null and b/client/public/trophy.png differ diff --git a/client/public/unity-logo.png b/client/public/unity-logo.png new file mode 100644 index 0000000..1ecf784 Binary files /dev/null and b/client/public/unity-logo.png differ diff --git a/client/public/vector.png b/client/public/vector.png new file mode 100644 index 0000000..2e31934 Binary files /dev/null and b/client/public/vector.png differ diff --git a/client/src/pages/healthcheck.tsx b/client/src/pages/healthcheck.tsx new file mode 100644 index 0000000..9d98316 --- /dev/null +++ b/client/src/pages/healthcheck.tsx @@ -0,0 +1,26 @@ +import { useState } from "react"; + +import { usePings } from "@/hooks/pings"; +import { cn } from "@/lib/utils"; + +import { Button } from "../components/ui/button"; + +export default function Home() { + const [clicked, setClicked] = useState(false); + const { data, isLoading } = usePings({ + enabled: clicked, + }); + + return ( +
+

Test title

+

Test subtitle

+ +

+ Response from server: {data as string} +

+
+ ); +} diff --git a/client/src/pages/index.tsx b/client/src/pages/index.tsx index 9d98316..a006d8f 100644 --- a/client/src/pages/index.tsx +++ b/client/src/pages/index.tsx @@ -1,26 +1,188 @@ -import { useState } from "react"; - -import { usePings } from "@/hooks/pings"; -import { cn } from "@/lib/utils"; +import Image from "next/image"; +import Link from "next/link"; import { Button } from "../components/ui/button"; -export default function Home() { - const [clicked, setClicked] = useState(false); - const { data, isLoading } = usePings({ - enabled: clicked, - }); +export default function Landing() { + const btnList = [ + { name: "More about us", link: "/committee/about" }, + { name: "Join our Discord", link: "" }, + ]; + + type cardImage = { + url: string; + width: number; + height: number; + alt: string; + }; + + type cardType = { + id: number; + title: string; + description: string; + type: string; + image: cardImage | null; + row: number; + }; + const eventCards = [ + { + id: 1, + title: "Game Jams", + description: + "Compete with a team over a short time period to develop your own game! Each game jam has a different theme so be prepared to think creatively.", + type: "default", + image: { + url: "/trophy.png", + width: 200, + height: 200, + alt: "Trophy", + }, + row: 1, + }, + { + id: 2, + title: "Social Events", + description: + "Meet other folks interested in game dev, play games, and maybe even recruit members for your next game jam team :P", + type: "default", + image: null, + row: 1, + }, + { + id: 3, + title: "Other Event Type", + description: + "Some other event type that the club runs! I'm not sure what, but this section might look better with four boxes…", + type: "default", + image: null, + row: 2, + }, + { + id: 4, + title: "Workshops", + description: + "Learn core Game Development technologies, such as Godot, Unity and more. Most workshops are presented by committee members with the chance to produce your own small game.", + type: "special-border", + image: null, + row: 2, + }, + ]; + + const logoImages = [ + { url: "/godot.png", alt: "Godot Logo", position: "start" }, + { url: "/unity-logo.png", alt: "Unity Logo", position: "end" }, + ]; + + const row1Cards = eventCards.filter((card) => card.row === 1); + const row2Cards = eventCards.filter((card) => card.row === 2); + + const renderCardHeader = (card: cardType) => { + if (card.type === "special-border") { + return ( +
+
+ {card.title} +
+
+ ); + } + + return ( +
+ {card.title} +
+ ); + }; + + const renderCard = (card: cardType) => ( +
+ {renderCardHeader(card)} + +
+
+ +

{card.description}

+ {card.image && ( + {card.image.alt} + )} +
+
+
+ ); return ( -
-

Test title

-

Test subtitle

- -

- Response from server: {data as string} -

+
+
+
+
+

+ Game Development UWA +

+

+ Little eye catching intro about what the club does here. Maybe + something about the purpose of the club, maybe something about the + type of events that the club runs. +

+
+ {btnList.map((item, i) => ( + + + + ))} +
+
+ + placeholder +
+
+ +
+
+
+ {row1Cards.map(renderCard)} +
+ +
+ {row2Cards.map(renderCard)} + +
+ {logoImages.map((logo, index) => ( + {logo.alt} + ))} +
+
+
+
); } diff --git a/client/src/styles/globals.css b/client/src/styles/globals.css index 6111245..c1bd5b0 100644 --- a/client/src/styles/globals.css +++ b/client/src/styles/globals.css @@ -48,6 +48,14 @@ --destructive: 0 62.8% 30.6%; --destructive-foreground: 0 0% 100%; + --landing-card1: 250, 44.3%, 15.5%; + + --landing-card2: 277 100% 62% / 0.1; + + --landing-card3: 232, 50.8%, 12%; + + --landing-border:235.1, 47.6%, 20%; + --border: 235 47% 20%; --input: 235 47% 20%; --ring: 236 47% 7%; diff --git a/client/tailwind.config.ts b/client/tailwind.config.ts index 915464d..9247338 100644 --- a/client/tailwind.config.ts +++ b/client/tailwind.config.ts @@ -27,6 +27,7 @@ const config = { colors: { border: "hsl(var(--border))", + landingBorder: "hsl(var(--landing-border))", input: "hsl(var(--input))", ring: "hsl(var(--ring))", background: "hsl(var(--background))", @@ -43,6 +44,9 @@ const config = { DEFAULT: "hsl(var(--destructive))", foreground: "hsl(var(--destructive-foreground))", }, + landingCard1: "hsl(var(--landing-card1))", + landingCard2: "hsl(var(--landing-card2))", + landingCard3: "hsl(var(--landing-card3))", muted: { DEFAULT: "hsl(var(--muted))", foreground: "hsl(var(--muted-foreground))",