import { Dispatch, FC, SetStateAction } from "react"; import { useRouter } from "next/router"; import Link from "next/link"; import { ArrowLeft, Plus } from "lucide-react"; // components // ui import { Breadcrumbs, BreadcrumbItem, Button, Tooltip } from "@plane/ui"; import { Icon } from "components/ui"; // helper import { replaceUnderscoreIfSnakeCase, truncateText } from "helpers/string.helper"; export interface IModulesHeader { name: string | undefined; modulesView: string; setModulesView: Dispatch>; } const moduleViewOptions: { type: "grid" | "gantt_chart"; icon: any }[] = [ { type: "gantt_chart", icon: "view_timeline", }, { type: "grid", icon: "table_rows", }, ]; export const ModulesHeader: FC = (props) => { const { name, modulesView, setModulesView } = props; // router const router = useRouter(); const { workspaceSlug } = router.query; return (
router.back()}>

Projects

} />
{moduleViewOptions.map((option) => ( {replaceUnderscoreIfSnakeCase(option.type)} Layout} position="bottom" > ))}
); };