'use client'
import { paths } from '@/routes/paths';
import { _project } from '@/shared/_mock/_projects';
import { useGetProject } from '@/shared/api/project';
import { LoadingScreen } from '@/shared/components/loading-screen';
import { NotFoundView } from '@/shared/sections/error';
import ProjectView from '@/shared/sections/project-details';
import { useRouter } from 'next/router';

// ----------------------------------------------------------------------



type Props = {
  params: {
    id: number;
  };
};

export default function ProjectDetailsPage({ params }: Props) {
  const { id } = params;

  const { ProjectData, projectIsLoading } = useGetProject(id);
  if (!ProjectData) {
    return <LoadingScreen />;
  }
  return <ProjectView project={ProjectData} />
}