import EntryDetailClient from "./EntryDetail";
import { getEntryById } from "@/server/repo/zxdb";

export const metadata = {
  title: "ZXDB Entry",
};

export const revalidate = 3600;

export default async function Page({ params }: { params: Promise<{ id: string }> }) {
  const { id } = await params;
  const numericId = Number(id);
  const data = await getEntryById(numericId);
  // For simplicity, let the client render a Not Found state if null
  return <EntryDetailClient data={data as any} />;
}
