@thepocman/gantt-task-react 1.0.34 → 1.0.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,6 +6,7 @@ export type TaskItemProps = {
6
6
  children?: React.ReactNode;
7
7
  getTaskGlobalIndexByRef: (task: Task) => number;
8
8
  hasChildren: boolean;
9
+ isInCollapsedGroup: boolean;
9
10
  rowIndexToTasksMap: RowIndexToTasksMap;
10
11
  taskToRowIndexMap: TaskToRowIndexMap;
11
12
  hasDependencyWarning: boolean;
@@ -4228,7 +4228,6 @@ const TaskListTableDefaultInner = ({
4228
4228
  if (taskIndex) {
4229
4229
  [depth, indexStr] = taskIndex;
4230
4230
  }
4231
- console.log("colors :>> ", colors);
4232
4231
  renderList.push(
4233
4232
  /* @__PURE__ */ jsx(
4234
4233
  TaskListTableRow,
@@ -5577,31 +5576,6 @@ const RelationLine = ({
5577
5576
  }
5578
5577
  );
5579
5578
  };
5580
- const truncateText = (text, maxWidth, textElement) => {
5581
- if (!textElement)
5582
- return text;
5583
- textElement.textContent = text;
5584
- const fullWidth = textElement.getBBox().width;
5585
- if (fullWidth <= maxWidth) {
5586
- return text;
5587
- }
5588
- let start = 0;
5589
- let end = text.length;
5590
- let result = text;
5591
- while (start <= end) {
5592
- const mid = Math.floor((start + end) / 2);
5593
- const truncated = text.substring(0, mid);
5594
- textElement.textContent = truncated;
5595
- const truncatedWidth = textElement.getBBox().width;
5596
- if (truncatedWidth <= maxWidth) {
5597
- result = truncated;
5598
- start = mid + 1;
5599
- } else {
5600
- end = mid - 1;
5601
- }
5602
- }
5603
- return result;
5604
- };
5605
5579
  const hoverVisibleWrapper = "_hoverVisibleWrapper_8hbnp_1";
5606
5580
  const wrapper = "_wrapper_8hbnp_1";
5607
5581
  const mainPath = "_mainPath_8hbnp_17";
@@ -6297,11 +6271,13 @@ const Milestone = ({
6297
6271
  }
6298
6272
  );
6299
6273
  };
6300
- const barLabel = "_barLabel_7emdt_1";
6301
- const barLabelOutside = "_barLabelOutside_7emdt_25";
6274
+ const barLabel = "_barLabel_y55xa_1";
6275
+ const barLabelOutside = "_barLabelOutside_y55xa_25";
6276
+ const barLabelTruncated = "_barLabelTruncated_y55xa_45";
6302
6277
  const style = {
6303
6278
  barLabel,
6304
- barLabelOutside
6279
+ barLabelOutside,
6280
+ barLabelTruncated
6305
6281
  };
6306
6282
  const TaskWarningInner = ({
6307
6283
  rtl,
@@ -6375,7 +6351,6 @@ const TaskWarningInner = ({
6375
6351
  };
6376
6352
  const TaskWarning = memo(TaskWarningInner);
6377
6353
  const TaskItemInner = (props) => {
6378
- var _a, _b, _c;
6379
6354
  const {
6380
6355
  childOutOfParentWarnings,
6381
6356
  colorStyles: stylesProp,
@@ -6402,11 +6377,10 @@ const TaskItemInner = (props) => {
6402
6377
  isRelationChangeable,
6403
6378
  ganttRelationEvent,
6404
6379
  rtl,
6380
+ enableTaskGrouping,
6381
+ isInCollapsedGroup,
6405
6382
  selectTaskOnMouseDown,
6406
6383
  setTooltipTask,
6407
- enableTaskGrouping,
6408
- taskToRowIndexMap,
6409
- rowIndexToTasksMap,
6410
6384
  task,
6411
6385
  task: { styles: taskStyles },
6412
6386
  taskHalfHeight,
@@ -6459,11 +6433,6 @@ const TaskItemInner = (props) => {
6459
6433
  const globalIndex = getTaskGlobalIndexByRef(task);
6460
6434
  fixEndPosition(task, end.date, globalIndex);
6461
6435
  }, [task, fixEndPosition, outOfParentWarnings, getTaskGlobalIndexByRef]);
6462
- const taskRowIndex = (_a = taskToRowIndexMap == null ? void 0 : taskToRowIndexMap.get(task.comparisonLevel ?? 1)) == null ? void 0 : _a.get(task.id);
6463
- if (taskRowIndex === void 0)
6464
- return null;
6465
- const isSharedRow = (((_c = (_b = rowIndexToTasksMap == null ? void 0 : rowIndexToTasksMap.get(task.comparisonLevel ?? 1)) == null ? void 0 : _b.get(taskRowIndex)) == null ? void 0 : _c.length) ?? 0) > 1;
6466
- const isInCollapsedGroup = !!enableTaskGrouping && isSharedRow;
6467
6436
  const handleClick = useCallback(
6468
6437
  (event) => {
6469
6438
  if (onClick) {
@@ -6497,8 +6466,6 @@ const TaskItemInner = (props) => {
6497
6466
  }, [onRelationStart, rtl, task]);
6498
6467
  const textRef = useRef(null);
6499
6468
  const [isTextInside, setIsTextInside] = useState(true);
6500
- const [truncatedText, setTruncatedText] = useState(task.name);
6501
- console.log("truncatedText", truncatedText);
6502
6469
  const taskItem = useMemo(() => {
6503
6470
  const isFromStartRelationAuthorized = authorizedRelations.includes("startToStart") || authorizedRelations.includes("startToEnd");
6504
6471
  const isFromEndRelationAuthorized = authorizedRelations.includes("endToEnd") || authorizedRelations.includes("endToStart");
@@ -6580,16 +6547,12 @@ const TaskItemInner = (props) => {
6580
6547
  task,
6581
6548
  width
6582
6549
  ]);
6550
+ const isGrouped = enableTaskGrouping && isInCollapsedGroup;
6583
6551
  useEffect(() => {
6584
- if (!textRef.current)
6585
- return;
6586
- if (isInCollapsedGroup) {
6587
- const truncated = truncateText(task.name, width - 10, textRef.current);
6588
- setTruncatedText(truncated);
6589
- } else {
6552
+ if (textRef.current) {
6590
6553
  setIsTextInside(textRef.current.getBBox().width < width);
6591
6554
  }
6592
- }, [isInCollapsedGroup, task.name, width]);
6555
+ }, [textRef, width]);
6593
6556
  const x3 = useMemo(() => {
6594
6557
  if (isTextInside) {
6595
6558
  return x1 + width * 0.5;
@@ -6599,9 +6562,7 @@ const TaskItemInner = (props) => {
6599
6562
  }
6600
6563
  return x1 + width + arrowIndent * 1.2;
6601
6564
  }, [x1, width, isTextInside, rtl, arrowIndent]);
6602
- const textForRender = isInCollapsedGroup ? "" : task.name;
6603
- console.log("testForRender", textForRender);
6604
- const xForRender = isInCollapsedGroup ? x1 + width * 0.5 : x3;
6565
+ const textForRender = isGrouped ? "" : task.name;
6605
6566
  const onMouseDown = useCallback(
6606
6567
  (event) => {
6607
6568
  selectTaskOnMouseDown(task.id, event);
@@ -6618,6 +6579,7 @@ const TaskItemInner = (props) => {
6618
6579
  setTooltipTask(null, null);
6619
6580
  }, [setTooltipTask]);
6620
6581
  let barLabelFill = isTextInside || task.type == "milestone" ? styles2.barLabelColor : styles2.barLabelWhenOutsideColor;
6582
+ let defaultBehavior = isTextInside ? style.barLabel : style.barLabel && style.barLabelOutside;
6621
6583
  return /* @__PURE__ */ jsxs(
6622
6584
  "g",
6623
6585
  {
@@ -6645,9 +6607,9 @@ const TaskItemInner = (props) => {
6645
6607
  "text",
6646
6608
  {
6647
6609
  fill: barLabelFill,
6648
- x: xForRender,
6610
+ x: x3,
6649
6611
  y: taskYOffset + taskHeight * 0.5,
6650
- className: isTextInside ? style.barLabel : style.barLabel && style.barLabelOutside,
6612
+ className: defaultBehavior,
6651
6613
  ref: textRef,
6652
6614
  children: textForRender
6653
6615
  }
@@ -6768,6 +6730,8 @@ const TaskGanttContent = ({
6768
6730
  for (const task of tasksAtRow) {
6769
6731
  const comparisonLevel = task.comparisonLevel ?? 1;
6770
6732
  const { id: taskId } = task;
6733
+ const isInCollapsedGroup = enableTaskGrouping && task.parent && tasksAtRow.length > 1;
6734
+ console.log("isInCollapsedGroup :>> ", isInCollapsedGroup);
6771
6735
  if (selectedIdsMirror[taskId] && !addedSelectedTasks[taskId]) {
6772
6736
  addedSelectedTasks[taskId] = true;
6773
6737
  const rowIndex = (_a = taskToRowIndexMap.get(comparisonLevel)) == null ? void 0 : _a.get(taskId);
@@ -6818,6 +6782,7 @@ const TaskGanttContent = ({
6818
6782
  children: /* @__PURE__ */ jsx(
6819
6783
  TaskItem,
6820
6784
  {
6785
+ isInCollapsedGroup,
6821
6786
  enableTaskGrouping,
6822
6787
  taskToRowIndexMap,
6823
6788
  rowIndexToTasksMap,
@@ -13193,6 +13158,7 @@ const Gantt = ({
13193
13158
  const barProps = useMemo(
13194
13159
  () => ({
13195
13160
  enableTaskGrouping,
13161
+ taskMap: tasksMap,
13196
13162
  rowIndexToTasksMap,
13197
13163
  authorizedRelations,
13198
13164
  additionalLeftSpace,
@@ -13244,6 +13210,7 @@ const Gantt = ({
13244
13210
  additionalLeftSpace,
13245
13211
  additionalRightSpace,
13246
13212
  enableTaskGrouping,
13213
+ tasksMap,
13247
13214
  rowIndexToTasksMap,
13248
13215
  checkIsHoliday,
13249
13216
  childOutOfParentWarnings,
@@ -4241,7 +4241,6 @@
4241
4241
  if (taskIndex) {
4242
4242
  [depth, indexStr] = taskIndex;
4243
4243
  }
4244
- console.log("colors :>> ", colors);
4245
4244
  renderList.push(
4246
4245
  /* @__PURE__ */ jsxRuntime.jsx(
4247
4246
  TaskListTableRow,
@@ -5590,31 +5589,6 @@
5590
5589
  }
5591
5590
  );
5592
5591
  };
5593
- const truncateText = (text, maxWidth, textElement) => {
5594
- if (!textElement)
5595
- return text;
5596
- textElement.textContent = text;
5597
- const fullWidth = textElement.getBBox().width;
5598
- if (fullWidth <= maxWidth) {
5599
- return text;
5600
- }
5601
- let start = 0;
5602
- let end = text.length;
5603
- let result = text;
5604
- while (start <= end) {
5605
- const mid = Math.floor((start + end) / 2);
5606
- const truncated = text.substring(0, mid);
5607
- textElement.textContent = truncated;
5608
- const truncatedWidth = textElement.getBBox().width;
5609
- if (truncatedWidth <= maxWidth) {
5610
- result = truncated;
5611
- start = mid + 1;
5612
- } else {
5613
- end = mid - 1;
5614
- }
5615
- }
5616
- return result;
5617
- };
5618
5592
  const hoverVisibleWrapper = "_hoverVisibleWrapper_8hbnp_1";
5619
5593
  const wrapper = "_wrapper_8hbnp_1";
5620
5594
  const mainPath = "_mainPath_8hbnp_17";
@@ -6310,11 +6284,13 @@
6310
6284
  }
6311
6285
  );
6312
6286
  };
6313
- const barLabel = "_barLabel_7emdt_1";
6314
- const barLabelOutside = "_barLabelOutside_7emdt_25";
6287
+ const barLabel = "_barLabel_y55xa_1";
6288
+ const barLabelOutside = "_barLabelOutside_y55xa_25";
6289
+ const barLabelTruncated = "_barLabelTruncated_y55xa_45";
6315
6290
  const style = {
6316
6291
  barLabel,
6317
- barLabelOutside
6292
+ barLabelOutside,
6293
+ barLabelTruncated
6318
6294
  };
6319
6295
  const TaskWarningInner = ({
6320
6296
  rtl,
@@ -6388,7 +6364,6 @@
6388
6364
  };
6389
6365
  const TaskWarning = React.memo(TaskWarningInner);
6390
6366
  const TaskItemInner = (props) => {
6391
- var _a, _b, _c;
6392
6367
  const {
6393
6368
  childOutOfParentWarnings,
6394
6369
  colorStyles: stylesProp,
@@ -6415,11 +6390,10 @@
6415
6390
  isRelationChangeable,
6416
6391
  ganttRelationEvent,
6417
6392
  rtl,
6393
+ enableTaskGrouping,
6394
+ isInCollapsedGroup,
6418
6395
  selectTaskOnMouseDown,
6419
6396
  setTooltipTask,
6420
- enableTaskGrouping,
6421
- taskToRowIndexMap,
6422
- rowIndexToTasksMap,
6423
6397
  task,
6424
6398
  task: { styles: taskStyles },
6425
6399
  taskHalfHeight,
@@ -6472,11 +6446,6 @@
6472
6446
  const globalIndex = getTaskGlobalIndexByRef(task);
6473
6447
  fixEndPosition(task, end.date, globalIndex);
6474
6448
  }, [task, fixEndPosition, outOfParentWarnings, getTaskGlobalIndexByRef]);
6475
- const taskRowIndex = (_a = taskToRowIndexMap == null ? void 0 : taskToRowIndexMap.get(task.comparisonLevel ?? 1)) == null ? void 0 : _a.get(task.id);
6476
- if (taskRowIndex === void 0)
6477
- return null;
6478
- const isSharedRow = (((_c = (_b = rowIndexToTasksMap == null ? void 0 : rowIndexToTasksMap.get(task.comparisonLevel ?? 1)) == null ? void 0 : _b.get(taskRowIndex)) == null ? void 0 : _c.length) ?? 0) > 1;
6479
- const isInCollapsedGroup = !!enableTaskGrouping && isSharedRow;
6480
6449
  const handleClick = React.useCallback(
6481
6450
  (event) => {
6482
6451
  if (onClick) {
@@ -6510,8 +6479,6 @@
6510
6479
  }, [onRelationStart, rtl, task]);
6511
6480
  const textRef = React.useRef(null);
6512
6481
  const [isTextInside, setIsTextInside] = React.useState(true);
6513
- const [truncatedText, setTruncatedText] = React.useState(task.name);
6514
- console.log("truncatedText", truncatedText);
6515
6482
  const taskItem = React.useMemo(() => {
6516
6483
  const isFromStartRelationAuthorized = authorizedRelations.includes("startToStart") || authorizedRelations.includes("startToEnd");
6517
6484
  const isFromEndRelationAuthorized = authorizedRelations.includes("endToEnd") || authorizedRelations.includes("endToStart");
@@ -6593,16 +6560,12 @@
6593
6560
  task,
6594
6561
  width
6595
6562
  ]);
6563
+ const isGrouped = enableTaskGrouping && isInCollapsedGroup;
6596
6564
  React.useEffect(() => {
6597
- if (!textRef.current)
6598
- return;
6599
- if (isInCollapsedGroup) {
6600
- const truncated = truncateText(task.name, width - 10, textRef.current);
6601
- setTruncatedText(truncated);
6602
- } else {
6565
+ if (textRef.current) {
6603
6566
  setIsTextInside(textRef.current.getBBox().width < width);
6604
6567
  }
6605
- }, [isInCollapsedGroup, task.name, width]);
6568
+ }, [textRef, width]);
6606
6569
  const x3 = React.useMemo(() => {
6607
6570
  if (isTextInside) {
6608
6571
  return x1 + width * 0.5;
@@ -6612,9 +6575,7 @@
6612
6575
  }
6613
6576
  return x1 + width + arrowIndent * 1.2;
6614
6577
  }, [x1, width, isTextInside, rtl, arrowIndent]);
6615
- const textForRender = isInCollapsedGroup ? "" : task.name;
6616
- console.log("testForRender", textForRender);
6617
- const xForRender = isInCollapsedGroup ? x1 + width * 0.5 : x3;
6578
+ const textForRender = isGrouped ? "" : task.name;
6618
6579
  const onMouseDown = React.useCallback(
6619
6580
  (event) => {
6620
6581
  selectTaskOnMouseDown(task.id, event);
@@ -6631,6 +6592,7 @@
6631
6592
  setTooltipTask(null, null);
6632
6593
  }, [setTooltipTask]);
6633
6594
  let barLabelFill = isTextInside || task.type == "milestone" ? styles2.barLabelColor : styles2.barLabelWhenOutsideColor;
6595
+ let defaultBehavior = isTextInside ? style.barLabel : style.barLabel && style.barLabelOutside;
6634
6596
  return /* @__PURE__ */ jsxRuntime.jsxs(
6635
6597
  "g",
6636
6598
  {
@@ -6658,9 +6620,9 @@
6658
6620
  "text",
6659
6621
  {
6660
6622
  fill: barLabelFill,
6661
- x: xForRender,
6623
+ x: x3,
6662
6624
  y: taskYOffset + taskHeight * 0.5,
6663
- className: isTextInside ? style.barLabel : style.barLabel && style.barLabelOutside,
6625
+ className: defaultBehavior,
6664
6626
  ref: textRef,
6665
6627
  children: textForRender
6666
6628
  }
@@ -6781,6 +6743,8 @@
6781
6743
  for (const task of tasksAtRow) {
6782
6744
  const comparisonLevel = task.comparisonLevel ?? 1;
6783
6745
  const { id: taskId } = task;
6746
+ const isInCollapsedGroup = enableTaskGrouping && task.parent && tasksAtRow.length > 1;
6747
+ console.log("isInCollapsedGroup :>> ", isInCollapsedGroup);
6784
6748
  if (selectedIdsMirror[taskId] && !addedSelectedTasks[taskId]) {
6785
6749
  addedSelectedTasks[taskId] = true;
6786
6750
  const rowIndex = (_a = taskToRowIndexMap.get(comparisonLevel)) == null ? void 0 : _a.get(taskId);
@@ -6831,6 +6795,7 @@
6831
6795
  children: /* @__PURE__ */ jsxRuntime.jsx(
6832
6796
  TaskItem,
6833
6797
  {
6798
+ isInCollapsedGroup,
6834
6799
  enableTaskGrouping,
6835
6800
  taskToRowIndexMap,
6836
6801
  rowIndexToTasksMap,
@@ -13206,6 +13171,7 @@
13206
13171
  const barProps = React.useMemo(
13207
13172
  () => ({
13208
13173
  enableTaskGrouping,
13174
+ taskMap: tasksMap,
13209
13175
  rowIndexToTasksMap,
13210
13176
  authorizedRelations,
13211
13177
  additionalLeftSpace,
@@ -13257,6 +13223,7 @@
13257
13223
  additionalLeftSpace,
13258
13224
  additionalRightSpace,
13259
13225
  enableTaskGrouping,
13226
+ tasksMap,
13260
13227
  rowIndexToTasksMap,
13261
13228
  checkIsHoliday,
13262
13229
  childOutOfParentWarnings,
package/dist/style.css CHANGED
@@ -520,7 +520,7 @@
520
520
  ._milestoneBackground_vcirf_11 {
521
521
  user-select: none;
522
522
  }
523
- ._barLabel_7emdt_1 {
523
+ ._barLabel_y55xa_1 {
524
524
  text-anchor: middle;
525
525
  font-weight: lighter;
526
526
  dominant-baseline: central;
@@ -532,7 +532,7 @@
532
532
  pointer-events: none;
533
533
  }
534
534
 
535
- ._barLabelOutside_7emdt_25 {
535
+ ._barLabelOutside_y55xa_25 {
536
536
  text-anchor: start;
537
537
  -webkit-touch-callout: none;
538
538
  -webkit-user-select: none;
@@ -540,6 +540,11 @@
540
540
  -ms-user-select: none;
541
541
  user-select: none;
542
542
  pointer-events: none;
543
+ }
544
+
545
+ ._barLabelTruncated_y55xa_45 {
546
+ text-anchor: middle;
547
+ dominant-baseline: middle;
543
548
  }._menuOption_z7pb4_1 {
544
549
  display: flex;
545
550
  align-items: center;
@@ -163,6 +163,7 @@ export interface Task {
163
163
  comparisonLevel?: number;
164
164
  status?: string;
165
165
  phase?: string;
166
+ taskOwner?: string;
166
167
  }
167
168
  export interface EmptyTask {
168
169
  id: string;
@@ -173,6 +174,7 @@ export interface EmptyTask {
173
174
  comparisonLevel?: number;
174
175
  status?: string;
175
176
  phase?: string;
177
+ taskOwner?: string;
176
178
  displayOrder?: number;
177
179
  isDisabled?: boolean;
178
180
  styles?: Partial<ColorStyles>;
package/package.json CHANGED
@@ -1,133 +1,138 @@
1
- {
2
- "name": "@thepocman/gantt-task-react",
3
- "version": "1.0.34",
4
- "description": "Fork of gantt-task-react with support for grouped tasks on a single row when collapsed",
5
- "author": "Adrian Bueno <adrianlbueno@users.noreply.github.com>",
6
- "homepage": "https://github.com/adrianlbueno/gantt-task-react#readme",
7
- "license": "MIT",
8
- "contributors": [
9
- {
10
- "name": "MaTeMaTuK",
11
- "url": "https://github.com/MaTeMaTuK"
12
- },
13
- {
14
- "name": "Janlaywss",
15
- "url": "https://github.com/Janlaywss"
16
- },
17
- {
18
- "name": "Adrian Bueno",
19
- "url": "https://github.com/adrianlbueno"
20
- }
21
- ],
22
- "repository": {
23
- "type": "git",
24
- "url": "git+https://github.com/adrianlbueno/gantt-task-react.git"
25
- },
26
- "publishConfig": {
27
- "access": "public"
28
- },
29
- "main": "./dist/gantt-task-react.umd.js",
30
- "module": "./dist/gantt-task-react.es.js",
31
- "types": "./dist/index.d.ts",
32
- "source": "src/index.tsx",
33
- "keywords": [
34
- "react",
35
- "gantt",
36
- "typescript",
37
- "chart",
38
- "svg",
39
- "gantt-chart",
40
- "gantt chart",
41
- "react-gantt",
42
- "task"
43
- ],
44
- "scripts": {
45
- "storybook": "storybook dev",
46
- "build": "vite build && tsc",
47
- "start": "vite --host",
48
- "prepare": "run-s build",
49
- "test": "run-s test:unit test:lint test:build",
50
- "test:build": "run-s build",
51
- "test:lint": "eslint --ext .tsx src/**/*",
52
- "test:unit": "cross-env CI=1 react-scripts test --env=jsdom",
53
- "test:watch": "react-scripts test --env=jsdom",
54
- "predeploy": "yarn storybook build",
55
- "deploy-storybook": "gh-pages -d storybook-static",
56
- "build-storybook": "storybook build"
57
- },
58
- "dependencies": {
59
- "@floating-ui/dom": "1.1.1",
60
- "@floating-ui/react": "0.19.2",
61
- "date-fns": "2.29.3"
62
- },
63
- "overrides": {
64
- "typescript": "~5.1.6"
65
- },
66
- "peerDependencies": {
67
- "@mui/icons-material": "^6.1.0",
68
- "@mui/material": "^6.1.0",
69
- "react": ">=18.0.0",
70
- "react-dom": ">=18.0.0"
71
- },
72
- "devDependencies": {
73
- "@babel/plugin-transform-regenerator": "~7.20.5",
74
- "@babel/types": "~7.20.7",
75
- "@emotion/react": "11.13.5",
76
- "@emotion/styled": "11.13.5",
77
- "@mdx-js/react": "~2.2.1",
78
- "@mui/icons-material": "^6.1.9",
79
- "@mui/material": "^6.1.9",
80
- "@rollup/plugin-image": "2.1.1",
81
- "@storybook/addon-controls": "~7.6.20",
82
- "@storybook/addon-docs": "~7.6.20",
83
- "@storybook/addons": "~7.6.20",
84
- "@storybook/channel-postmessage": "~7.6.20",
85
- "@storybook/channel-websocket": "~7.6.20",
86
- "@storybook/client-api": "~7.6.20",
87
- "@storybook/mdx2-csf": "~1.1.0",
88
- "@storybook/node-logger": "~7.6.20",
89
- "@storybook/preview-web": "~7.6.20",
90
- "@storybook/react": "~7.6.20",
91
- "@storybook/react-vite": "~7.6.20",
92
- "@testing-library/jest-dom": "~5.16.5",
93
- "@testing-library/react": "~16.0.1",
94
- "@testing-library/user-event": "~14.2.6",
95
- "@types/jest": "~27.5.2",
96
- "@types/node": "~15.0.3",
97
- "@types/react": "~18.3.12",
98
- "@types/react-dom": "~18.3.1",
99
- "@vitejs/plugin-react": "4.0.4",
100
- "cross-env": "~7.0.3",
101
- "doctrine": "~3.0.0",
102
- "eslint": "^8.50.0",
103
- "eslint-config-react-app": "^7.0.1",
104
- "gh-pages": "~5.0.0",
105
- "identity-obj-proxy": "~3.0.0",
106
- "jsdom": "^25.0.1",
107
- "mini-css-extract-plugin": "~2.7.7",
108
- "npm-run-all": "~4.1.5",
109
- "postcss-flexbugs-fixes": "~5.0.2",
110
- "postcss-normalize": "~10.0.1",
111
- "postcss-preset-env": "~8.0.1",
112
- "prettier": "~2.8.8",
113
- "react": "~18.3.1",
114
- "react-dom": "~18.3.1",
115
- "react-scripts": "^5.0.1",
116
- "rollup-plugin-peer-deps-external": "2.2.4",
117
- "storybook": "7.6.20",
118
- "typescript": "~5.1.6",
119
- "vite": "^4.5.5",
120
- "vitest": "0.34.6"
121
- },
122
- "files": [
123
- "dist"
124
- ],
125
- "jest": {
126
- "transformIgnorePatterns": [
127
- "/node_modules/(?!react-dnd|core-dnd|@react-dnd|dnd-core|react-dnd-html5-backend)"
128
- ],
129
- "moduleNameMapper": {
130
- "/~.+\\.module\\.(css|sass|scss)$/": "identity-obj-proxy"
131
- }
132
- }
133
- }
1
+ {
2
+ "name": "@thepocman/gantt-task-react",
3
+ "version": "1.0.36",
4
+ "description": "Fork of gantt-task-react with support for grouped tasks on a single row when collapsed",
5
+ "author": "Adrian Bueno <adrianlbueno@users.noreply.github.com>",
6
+ "homepage": "https://github.com/adrianlbueno/gantt-task-react#readme",
7
+ "license": "MIT",
8
+ "contributors": [
9
+ {
10
+ "name": "MaTeMaTuK",
11
+ "url": "https://github.com/MaTeMaTuK"
12
+ },
13
+ {
14
+ "name": "Janlaywss",
15
+ "url": "https://github.com/Janlaywss"
16
+ },
17
+ {
18
+ "name": "Adrian Bueno",
19
+ "url": "https://github.com/adrianlbueno"
20
+ }
21
+ ],
22
+ "repository": {
23
+ "type": "git",
24
+ "url": "git+https://github.com/adrianlbueno/gantt-task-react.git"
25
+ },
26
+ "publishConfig": {
27
+ "access": "public"
28
+ },
29
+ "main": "./dist/gantt-task-react.umd.js",
30
+ "module": "./dist/gantt-task-react.es.js",
31
+ "types": "./dist/index.d.ts",
32
+ "source": "src/index.tsx",
33
+ "keywords": [
34
+ "react",
35
+ "gantt",
36
+ "typescript",
37
+ "chart",
38
+ "svg",
39
+ "gantt-chart",
40
+ "gantt chart",
41
+ "react-gantt",
42
+ "task"
43
+ ],
44
+ "scripts": {
45
+ "storybook": "storybook dev",
46
+ "build": "vite build && tsc",
47
+ "start": "vite --host",
48
+ "prepare": "run-s build",
49
+ "test": "run-s test:unit test:lint test:build",
50
+ "test:build": "run-s build",
51
+ "test:lint": "eslint --ext .tsx src/**/*",
52
+ "test:unit": "cross-env CI=1 react-scripts test --env=jsdom",
53
+ "test:watch": "react-scripts test --env=jsdom",
54
+ "predeploy": "yarn storybook build",
55
+ "deploy-storybook": "gh-pages -d storybook-static",
56
+ "build-storybook": "storybook build"
57
+ },
58
+ "dependencies": {
59
+ "@floating-ui/dom": "1.1.1",
60
+ "@floating-ui/react": "0.19.2",
61
+ "date-fns": "2.29.3"
62
+ },
63
+ "overrides": {
64
+ "typescript": "~5.1.6"
65
+ },
66
+ "peerDependencies": {
67
+ "@mui/icons-material": "^6.1.0",
68
+ "@mui/material": "^6.1.0",
69
+ "react": ">=18.0.0",
70
+ "react-dom": ">=18.0.0"
71
+ },
72
+ "devDependencies": {
73
+ "@babel/plugin-transform-regenerator": "~7.20.5",
74
+ "@babel/types": "~7.20.7",
75
+ "@emotion/react": "11.13.5",
76
+ "@emotion/styled": "11.13.5",
77
+ "@mdx-js/react": "~2.2.1",
78
+ "@mui/icons-material": "^6.1.9",
79
+ "@mui/material": "^6.1.9",
80
+ "@rollup/plugin-image": "2.1.1",
81
+ "@storybook/addon-controls": "~7.6.20",
82
+ "@storybook/addon-docs": "~7.6.20",
83
+ "@storybook/addons": "~7.6.20",
84
+ "@storybook/channel-postmessage": "~7.6.20",
85
+ "@storybook/channel-websocket": "~7.6.20",
86
+ "@storybook/client-api": "~7.6.20",
87
+ "@storybook/mdx2-csf": "~1.1.0",
88
+ "@storybook/node-logger": "~7.6.20",
89
+ "@storybook/preview-web": "~7.6.20",
90
+ "@storybook/react": "~7.6.20",
91
+ "@storybook/react-vite": "~7.6.20",
92
+ "@testing-library/jest-dom": "~5.16.5",
93
+ "@testing-library/react": "~16.0.1",
94
+ "@testing-library/user-event": "~14.2.6",
95
+ "@types/jest": "~27.5.2",
96
+ "@types/node": "~15.0.3",
97
+ "@types/react": "~18.3.12",
98
+ "@types/react-dom": "~18.3.1",
99
+ "@vitejs/plugin-react": "4.0.4",
100
+ "cross-env": "~7.0.3",
101
+ "doctrine": "~3.0.0",
102
+ "eslint": "^8.50.0",
103
+ "eslint-config-react-app": "^7.0.1",
104
+ "gh-pages": "~5.0.0",
105
+ "identity-obj-proxy": "~3.0.0",
106
+ "jsdom": "^25.0.1",
107
+ "mini-css-extract-plugin": "~2.7.7",
108
+ "npm-run-all": "~4.1.5",
109
+ "postcss-flexbugs-fixes": "~5.0.2",
110
+ "postcss-normalize": "~10.0.1",
111
+ "postcss-preset-env": "~8.0.1",
112
+ "prettier": "~2.8.8",
113
+ "react": "~18.3.1",
114
+ "react-dom": "~18.3.1",
115
+ "react-scripts": "^5.0.1",
116
+ "rollup-plugin-peer-deps-external": "2.2.4",
117
+ "storybook": "7.6.20",
118
+ "typescript": "~5.1.6",
119
+ "vite": "^4.5.5",
120
+ "vitest": "0.34.6"
121
+ },
122
+ "files": [
123
+ "dist"
124
+ ],
125
+ "jest": {
126
+ "transformIgnorePatterns": [
127
+ "/node_modules/(?!react-dnd|core-dnd|@react-dnd|dnd-core|react-dnd-html5-backend)"
128
+ ],
129
+ "moduleNameMapper": {
130
+ "/~.+\\.module\\.(css|sass|scss)$/": "identity-obj-proxy"
131
+ }
132
+ },
133
+ "eslintConfig": {
134
+ "extends": [
135
+ "plugin:storybook/recommended"
136
+ ]
137
+ }
138
+ }