quivr/frontend/app/brains-management/[brainId]/page.tsx

31 lines
765 B
TypeScript
Raw Normal View History

"use client";
2023-07-25 10:54:34 +03:00
import { UUID } from "crypto";
import { useParams } from "next/navigation";
import { BrainManagementTabs } from "./components/BrainManagementTabs/BrainManagementTabs";
const BrainsManagement = (): JSX.Element => {
2023-07-25 10:54:34 +03:00
const params = useParams();
const brainId = params?.brainId as UUID | undefined;
if (brainId === undefined) {
return (
<div className="flex justify-center mt-5 w-full">
<div className="bg-blue-100 border border-blue-400 text-blue-700 px-4 py-3 rounded relative max-w-md h-fit">
<p>Select a brain please</p>
</div>
</div>
);
}
return (
2023-07-25 10:54:34 +03:00
<main className="flex flex-col w-full pt-20 px-20">
<BrainManagementTabs />
</main>
);
};
export default BrainsManagement;