Add Turnstile protection to user actions
This commit is contained in:
@@ -22,6 +22,7 @@ import { resolveRedirect } from "@/lib/seo/redirects";
|
||||
import { siteConfig } from "@/lib/site";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
const turnstileSiteKey = process.env.TURNSTILE_SITE_KEY ?? "";
|
||||
|
||||
type Args = { params: Promise<{ slug: string }> };
|
||||
const WEEKDAY_LABELS: Record<string, string> = { monday: "Montag", tuesday: "Dienstag", wednesday: "Mittwoch", thursday: "Donnerstag", friday: "Freitag", saturday: "Samstag", sunday: "Sonntag" };
|
||||
@@ -138,7 +139,7 @@ export default async function OfferDetailPage({ params }: Args) {
|
||||
)}
|
||||
{offer.groupCapacity && <p className="mb-2 text-sm text-anouma-plum/75">Plätze: {offer.groupCapacity}</p>}
|
||||
{offer.registrationDeadline && <p className="mb-6 text-sm text-anouma-plum/75">Anmeldung möglich bis {new Date(offer.registrationDeadline).toLocaleDateString("de-DE")}</p>}
|
||||
<GroupRegistrationForm offerSlug={offer.slug!} />
|
||||
<GroupRegistrationForm offerSlug={offer.slug!} siteKey={turnstileSiteKey} />
|
||||
</div>
|
||||
</Section>
|
||||
) : offer.bookable ? (
|
||||
|
||||
Reference in New Issue
Block a user