diff --git a/src/app/polycule/page.tsx b/src/app/polycule/page.tsx new file mode 100644 index 0000000..101036e --- /dev/null +++ b/src/app/polycule/page.tsx @@ -0,0 +1,33 @@ +import { Partner } from "@/components/partner"; +import { Rule } from "@/components/rule"; +import { Partners } from "@/config/Partners"; + +const Polycule = (): JSX.Element => { + return ( + <> +
+

Naomi's Polycule

+
+

+ Meet the people who love and support Naomi to the ends of the earth. +

+ +
+ {Partners.map((member) => ( + + ))} +
+
+
+ + ); +}; + +export default Polycule; diff --git a/src/components/partner.tsx b/src/components/partner.tsx new file mode 100644 index 0000000..0a84cb7 --- /dev/null +++ b/src/components/partner.tsx @@ -0,0 +1,47 @@ +import Image from "next/image"; +import { useState } from "react"; + +interface PartnerProps { + name: string; + avatar: string; + relationship: string; + url: string; + anniversary: Date; +} + +export const Partner = (props: PartnerProps): JSX.Element => { + const { name, avatar, relationship, url, anniversary } = props; + + return ( +
+ {`${name}'s +
+
+ + {name} + +

+ {anniversary.toLocaleDateString("en-GB", { + month: "long", + year: "numeric", + day: "numeric", + })} +

+
+

+ {relationship} +

+
+
+ ); +}; diff --git a/src/config/NavItems.ts b/src/config/NavItems.ts index 77116aa..013cae2 100644 --- a/src/config/NavItems.ts +++ b/src/config/NavItems.ts @@ -6,5 +6,6 @@ export const NavItems = [ { href: "/certs", text: "Certifications" }, { href: "/reviews", text: "Reviews" }, { href: "/games", text: "Games"}, - { href: "/team", text: "Our Team" } + { href: "/team", text: "Our Team" }, + { href: "/polycule", text: "Polycule"} ].sort((a, b) => a.text.localeCompare(b.text)); diff --git a/src/config/Partners.ts b/src/config/Partners.ts new file mode 100644 index 0000000..116d75b --- /dev/null +++ b/src/config/Partners.ts @@ -0,0 +1,29 @@ +export const Partners: { + name: string; + avatar: string; + relationship: string; + url: string; + anniversary: Date; + }[] = [ + { + name: "Sadashi", + avatar: "dashi.png", + relationship: "Romantic Partner", + url: "https://chat.nhcarrigan.com", + anniversary: new Date("January 1, 2023") + }, + { + name: "Rain", + avatar: "estel.png", + relationship: "Fiancée", + url: "https://chat.nhcarrigan.com", + anniversary: new Date("November 17, 2023") + }, + { + name: "Kaitlyn", + avatar: "fruit.png", + relationship: "Queer-Platonic Partner", + url: "https://kaitlyn.nhcarrigan.com", + anniversary: new Date("October 1, 2023") + }, + ].sort((a, b) => a.anniversary.getTime() - b.anniversary.getTime())