// components import { IBlockUpdateData, IGanttBlock } from "@/components/gantt-chart"; // constants import { HEADER_HEIGHT, SIDEBAR_WIDTH } from "../constants"; type Props = { blocks: IGanttBlock[] | null; blockUpdateHandler: (block: any, payload: IBlockUpdateData) => void; enableReorder: boolean; sidebarToRender: (props: any) => React.ReactNode; title: string; quickAdd?: React.JSX.Element | undefined; }; export const GanttChartSidebar: React.FC = (props) => { const { blocks, blockUpdateHandler, enableReorder, sidebarToRender, title, quickAdd } = props; return (
{title}
Duration
{sidebarToRender && sidebarToRender({ title, blockUpdateHandler, blocks, enableReorder })}
{quickAdd ? quickAdd : null}
); };