import type { Metadata } from "next";
import { ChangelogList } from "@/components/shared/changelog-list";
import { APP_VERSION } from "@/lib/changelog";
import { requireFullAdminPage } from "@/lib/require-admin-page";

export const metadata: Metadata = {};

export default async function AdminChangelogPage() {
  await requireFullAdminPage();
  return (
    <div className="space-y-6">
      <div>
        <h1 className="text-2xl font-bold tracking-tight">Changelog</h1>
        <p className="text-muted-foreground mt-1">Currently running v{APP_VERSION}. Edit apps/web/lib/changelog.ts to update.</p>
      </div>
      <ChangelogList />
    </div>
  );
}
