"use client";

import { useParams } from "next/navigation";
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card";

export default function DynamicAdminPage() {
  const params = useParams();
  const slug = params.slug as string[];
  const path = slug ? slug.join("/") : "";

  return (
    <div className="p-6">
      <Card>
        <CardHeader>
          <CardTitle>동적 관리자 페이지</CardTitle>
          <CardDescription>경로: /admin/{path}</CardDescription>
        </CardHeader>
        <CardContent>
          <p className="text-muted-foreground">이 페이지는 메뉴관리에서 등록한 URL에 의해 동적으로 생성되었습니다.</p>
          <p className="text-muted-foreground mt-2">경로: {path}</p>
        </CardContent>
      </Card>
    </div>
  );
}

