+48
-1
app/(home)/team/page.tsx
+48
-1
app/(home)/team/page.tsx
···
1
+
import { Metadata } from "next";
1
2
import Image from "next/image";
2
3
import Link from "next/link";
3
4
import { HiExternalLink } from "react-icons/hi";
4
5
5
6
import { getUser } from "@/lib/discord/user";
6
7
import { filterDuplicates } from "@/lib/filter-duplicates";
8
+
import MommyPic from "@/public/mommy.webp";
7
9
import cn from "@/utils/cn";
10
+
import { getBaseUrl, getCanonicalUrl } from "@/utils/urls";
8
11
9
12
enum TeamType {
10
13
Developer = "developer",
···
77
80
}
78
81
] as const;
79
82
83
+
export const generateMetadata = async (): Promise<Metadata> => {
84
+
const title = "Team";
85
+
const description = "Meet the creators of Wamellow and its products. Our dedicated team, including developers and donors, drives innovation and community growth.";
86
+
const url = getCanonicalUrl("team");
87
+
88
+
return {
89
+
title,
90
+
description,
91
+
alternates: {
92
+
canonical: url
93
+
},
94
+
openGraph: {
95
+
title,
96
+
description,
97
+
url,
98
+
type: "website",
99
+
images: {
100
+
url: `${getBaseUrl()}/mommy.webp`,
101
+
type: "image/webp"
102
+
}
103
+
},
104
+
twitter: {
105
+
card: "summary",
106
+
title,
107
+
description,
108
+
images: {
109
+
url: `${getBaseUrl()}/mommy.webp`,
110
+
alt: title
111
+
}
112
+
}
113
+
};
114
+
};
115
+
80
116
export default function Home() {
81
117
return (
82
118
<div>
83
119
<h2 className="text-2xl font-medium text-neutral-200">Team 🍪</h2>
120
+
<div className="max-w-xl">
121
+
Meet the creators of Wamellow and its products. Our dedicated team, including developers and donors, drives innovation and community growth
122
+
</div>
84
123
85
-
<div className="divide-y-1 divide-wamellow">
124
+
<div className="relative divide-y-1 divide-wamellow">
86
125
{filterDuplicates(data.map((person) => person.team)).map((team) => (
87
126
<div
88
127
key={team}
···
116
155
</div>
117
156
</div>
118
157
))}
158
+
159
+
<Image
160
+
alt="no mommy? 😢"
161
+
className="absolute right-0 top-0 shrink-0 aspect-square rounded-lg"
162
+
height={128}
163
+
src={MommyPic}
164
+
width={128}
165
+
/>
119
166
</div>
120
167
121
168
</div>
+3
-1
lib/discord/user.ts
+3
-1
lib/discord/user.ts
···
1
1
import { Collection } from "@discordjs/collection";
2
2
import { APIUser, RESTGetAPIUserResult, Routes } from "discord-api-types/v10";
3
3
4
-
import { rest } from ".";
4
+
import { rest } from "./index";
5
5
6
6
const cache = new Collection<string, User>();
7
7
···
11
11
this.username = data.username;
12
12
this.globalName = data.global_name || null;
13
13
this.avatar = data.avatar;
14
+
this.avatarUrl = data.avatar ? `https://cdn.discordapp.com/avatars/${data.id}/${data.avatar}.${data.avatar.startsWith("a_") ? "gif" : "webp"}` : null;
14
15
this.bot = data.bot || false;
15
16
}
16
17
···
18
19
public username: string;
19
20
public globalName: string | null;
20
21
public avatar: string | null;
22
+
public avatarUrl: string | null;
21
23
public bot: boolean;
22
24
}
23
25
public/mommy.webp
public/mommy.webp
This is a binary file and will not be displayed.