import { Route, Routes } from "react-router";

import { AdminConsoleLayout } from "./consoles/admin/AdminConsoleLayout";
import { ChatPage } from "./consoles/workbench/pages/ChatPage";
import { WorkbenchProjectGate } from "./consoles/workbench/WorkbenchProjectGate";
import { NotFoundPage } from "./pages/404";
import { DashboardPage } from "./pages/dashboard";
import { ModelsPage } from "./pages/models";
import { ProjectsPage } from "./pages/projects";

export function AppRoutes() {
  return (
    <Routes>
      <Route element={<AdminConsoleLayout />}>
        <Route element={<DashboardPage />} path="/" />
        <Route element={<ProjectsPage />} path="/projects" />
        <Route element={<ModelsPage />} path="/models" />
      </Route>
      <Route element={<WorkbenchProjectGate />} path="/workbench/:projectId">
        <Route element={<ChatPage />} path="" />
        <Route element={<ChatPage />} path="chat" />
      </Route>
      <Route element={<NotFoundPage />} path="*" />
    </Routes>
  );
}
