forked from github/plane
963d26ccda
* chore: gantt sidebar and main content scroll sync * chore: add arrow navigation position logic * refactor: scroll position update logic * refactor: gantt chart components * refactor: gantt sidebar * fix: vertical scroll issue * fix: move to the hidden block button flickering * refactor: gantt sidebar components * chore: move timeline header outside * fix gantt scroll issue * fix: sticky position issues * fix: infinite timeline scroll logic * chore: removed unnecessary import statements --------- Co-authored-by: rahulramesha <rahulramesham@gmail.com>
13 lines
429 B
TypeScript
13 lines
429 B
TypeScript
// types
|
|
import { TIssue } from "@plane/types";
|
|
import { IGanttBlock } from "components/gantt-chart";
|
|
|
|
export const renderIssueBlocksStructure = (blocks: TIssue[]): IGanttBlock[] =>
|
|
blocks?.map((block) => ({
|
|
data: block,
|
|
id: block.id,
|
|
sort_order: block.sort_order,
|
|
start_date: block.start_date ? new Date(block.start_date) : null,
|
|
target_date: block.target_date ? new Date(block.target_date) : null,
|
|
}));
|