Skip to content

Commit 9b6d8d5

Browse files
committed
fix: buttons; homepage drawings to svgs; canonical tags; css
1 parent 8dcdad3 commit 9b6d8d5

File tree

26 files changed

+253
-73
lines changed

26 files changed

+253
-73
lines changed

messages/bs.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1066,7 +1066,8 @@
10661066
"minimumChars": "Unesite najmanje 2 slova",
10671067
"noResults": "Nema rezultata",
10681068
"chooseUserDescription": "Ako je korisnik već na platformi, možete ga pronaći ovdje.",
1069-
"emailDescription": "Ako ne možete pronaći korisnika, ili već znate njihov email, unesite ga ovdje."
1069+
"emailDescription": "Ako ne možete pronaći korisnika, ili već znate njihov email, unesite ga ovdje.",
1070+
"or": "ili"
10701071
},
10711072
"managers": {
10721073
"promote": {

messages/en.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1017,7 +1017,8 @@
10171017
"minimumChars": "Enter at least 2 characters",
10181018
"noResults": "No results",
10191019
"chooseUserDescription": "If the user is already on the platform, you can find them here.",
1020-
"emailDescription": "If you can't find the user, or already know their email, enter it here."
1020+
"emailDescription": "If you can't find the user, or already know their email, enter it here.",
1021+
"or": "or"
10211022
},
10221023
"managers": {
10231024
"title": "Managers",

public/footer.webp

-69.2 KB
Binary file not shown.

public/home.webp

-103 KB
Binary file not shown.

public/peeking.webp

-54.7 KB
Binary file not shown.

src/app/[locale]/(public)/changelog/page.tsx

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,9 @@ import { SiGithub } from "@icons-pack/react-simple-icons";
99
import { remark } from "remark";
1010
import remarkHtml from "remark-html";
1111
import remarkGfm from "remark-gfm";
12-
import Peeking from "@public/peeking.webp";
13-
import Image from "next/image";
1412

1513
import "./markdown.css";
14+
import { PeekingDrawing } from "@/components/logos/drawings/peeking-drawing";
1615

1716
// Helper function to format GitHub release body markdown
1817
async function formatReleaseBody(body: string): Promise<string> {
@@ -101,14 +100,7 @@ export default async function ChangelogPage() {
101100

102101
{/* Latest Release */}
103102
<div className="relative mb-16">
104-
<Image
105-
priority={true}
106-
loading="eager"
107-
src={Peeking}
108-
alt="An airsoft player peeking from behind a wall"
109-
draggable={false}
110-
className="z-10 absolute -right-5 md:-right-0 -top-11 lg:-top-27 transition-all w-full max-w-[180px] lg:max-w-[300px] dark:invert"
111-
/>
103+
<PeekingDrawing className="z-10 absolute -right-5 md:-right-0 -top-11 lg:-top-27 transition-all w-full max-w-[180px] lg:max-w-[300px] dark:invert" />
112104
<h2 className="text-2xl font-bold mb-6">{t("latestRelease")}</h2>
113105
<Card className="relative overflow-hidden border-2 border-primary/20 shadow-lg">
114106
<CardHeader className="bg-primary/5">

src/app/[locale]/(public)/clubs/[id]/page.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,9 +106,14 @@ export async function generateMetadata(props: PageProps): Promise<Metadata> {
106106
ogUrl.searchParams.set("logo", club.logo);
107107
}
108108

109+
const canonicalUrl = `${env.NEXT_PUBLIC_BETTER_AUTH_URL}/clubs/${club.slug || club.id}`;
110+
109111
return {
110112
title: `${club.name} - RECONNED`,
111113
description: club.description?.slice(0, 160) ?? t("description"),
114+
alternates: {
115+
canonical: canonicalUrl,
116+
},
112117
openGraph: {
113118
images: [
114119
{

src/app/[locale]/(public)/clubs/page.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { Pagination } from "@/app/[locale]/(public)/_components/pagination";
44
import { SearchResultCard } from "@/app/[locale]/(public)/search/_components/search-result-card";
55
import { VerifiedClubIcon } from "@/components/icons";
66
import type { Metadata } from "next";
7+
import { env } from "@/lib/env";
78

89
const ITEMS_PER_PAGE = 12;
910

@@ -76,5 +77,8 @@ export async function generateMetadata(): Promise<Metadata> {
7677
keywords: t("layout.metadata.keywords")
7778
.split(",")
7879
.map((keyword) => keyword.trim()),
80+
alternates: {
81+
canonical: `${env.NEXT_PUBLIC_BETTER_AUTH_URL}/clubs`,
82+
},
7983
};
8084
}

src/app/[locale]/(public)/events/[id]/apply/page.tsx

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import { FEATURE_FLAGS } from "@/lib/server-utils";
88
import { isAfter, isBefore } from "date-fns";
99
import { getLocale, getTranslations } from "next-intl/server";
1010
import { notFound } from "next/navigation";
11+
import type { Metadata } from "next";
1112

1213
interface EventApplicationPageProps {
1314
params: Promise<{
@@ -146,3 +147,43 @@ export default async function EventApplicationPage(props: EventApplicationPagePr
146147
</div>
147148
);
148149
}
150+
151+
export async function generateMetadata(props: EventApplicationPageProps): Promise<Metadata> {
152+
const params = await props.params;
153+
const t = await getTranslations("public.events.metadata");
154+
155+
const event = await prisma.event.findFirst({
156+
where: {
157+
OR: [
158+
{
159+
id: params.id,
160+
},
161+
{
162+
slug: params.id,
163+
},
164+
],
165+
},
166+
select: {
167+
id: true,
168+
slug: true,
169+
name: true,
170+
description: true,
171+
},
172+
});
173+
174+
if (!event) {
175+
return {
176+
title: "Event Not Found - RECONNED",
177+
};
178+
}
179+
180+
const canonicalUrl = `${env.NEXT_PUBLIC_BETTER_AUTH_URL}/events/${event.slug || event.id}/apply`;
181+
182+
return {
183+
title: `Apply to ${event.name} - RECONNED`,
184+
description: `Apply to participate in ${event.name}`,
185+
alternates: {
186+
canonical: canonicalUrl,
187+
},
188+
};
189+
}

src/app/[locale]/(public)/events/[id]/page.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,14 @@ export async function generateMetadata(props: PageProps): Promise<Metadata> {
112112
ogUrl.searchParams.set("image", event.image);
113113
}
114114

115+
const canonicalUrl = `${env.NEXT_PUBLIC_BETTER_AUTH_URL}/events/${event.slug || event.id}`;
116+
115117
return {
116118
title: `${event.name} - RECONNED`,
117119
description: event.description.slice(0, 160) ?? t("description"),
120+
alternates: {
121+
canonical: canonicalUrl,
122+
},
118123
openGraph: {
119124
images: [
120125
{

0 commit comments

Comments
 (0)