refactor: gantt sidebar (#2705)
* refactor: gantt sidebar * fix: exception error fix: file placement * refactor: not passing sidebar block as props
This commit is contained in:
parent
79df59f618
commit
34bccd7e06
14 changed files with 232 additions and 49 deletions
|
|
@ -3,8 +3,8 @@ import { observer } from "mobx-react-lite";
|
|||
// mobx store
|
||||
import { useMobxStore } from "lib/mobx/store-provider";
|
||||
// components
|
||||
import { GanttChartRoot, IBlockUpdateData } from "components/gantt-chart";
|
||||
import { ModuleGanttBlock, ModuleGanttSidebarBlock } from "components/modules";
|
||||
import { GanttChartRoot, IBlockUpdateData, ModuleGanttSidebar } from "components/gantt-chart";
|
||||
import { ModuleGanttBlock } from "components/modules";
|
||||
// types
|
||||
import { IModule } from "types";
|
||||
|
||||
|
|
@ -44,8 +44,8 @@ export const ModulesListGanttChartView: React.FC = observer(() => {
|
|||
title="Modules"
|
||||
loaderTitle="Modules"
|
||||
blocks={modules ? blockFormat(modules) : null}
|
||||
sidebarToRender={(props) => <ModuleGanttSidebar {...props} />}
|
||||
blockUpdateHandler={(block, payload) => handleModuleUpdate(block, payload)}
|
||||
sidebarBlockToRender={ModuleGanttSidebarBlock}
|
||||
blockToRender={(data: IModule) => <ModuleGanttBlock data={data} />}
|
||||
enableBlockLeftResize={isAllowed}
|
||||
enableBlockRightResize={isAllowed}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue