22 lines
666 B
TypeScript
22 lines
666 B
TypeScript
import Link from "next/link"
|
|
import { getEventById } from "@/lib/mock-data"
|
|
import { MatchDetailView } from "@/components/betting/match-detail-view"
|
|
|
|
export default async function EventPage({ params }: { params: Promise<{ id: string }> }) {
|
|
const { id } = await params
|
|
const event = getEventById(id)
|
|
|
|
if (!event) {
|
|
return (
|
|
<div className="flex flex-col items-center justify-center min-h-[40vh] gap-4">
|
|
<p className="text-white/80">Match not found.</p>
|
|
<Link href="/" className="text-brand-primary font-bold hover:underline">
|
|
Back to home
|
|
</Link>
|
|
</div>
|
|
)
|
|
}
|
|
|
|
return <MatchDetailView event={event} />
|
|
}
|