gantt-task-react-v 1.2.10 → 1.2.11

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.
@@ -11113,14 +11113,15 @@ const calculateDataDatePosition = ({
11113
11113
  viewMode,
11114
11114
  columnWidth
11115
11115
  }) => {
11116
- const milestonePosition = taskXCoordinate(
11116
+ const milestoneCenter = taskXCoordinate(
11117
11117
  dataDate,
11118
11118
  startDate,
11119
11119
  viewMode,
11120
11120
  columnWidth
11121
11121
  );
11122
- const milestoneHalfWidth = 6;
11123
- return milestonePosition + milestoneHalfWidth;
11122
+ const taskHeight = 32;
11123
+ const milestoneRightEdge = milestoneCenter + taskHeight * 0.5;
11124
+ return milestoneRightEdge;
11124
11125
  };
11125
11126
  const GanttTodayInner = ({
11126
11127
  additionalLeftSpace,
@@ -11130,14 +11130,15 @@
11130
11130
  viewMode,
11131
11131
  columnWidth
11132
11132
  }) => {
11133
- const milestonePosition = taskXCoordinate(
11133
+ const milestoneCenter = taskXCoordinate(
11134
11134
  dataDate,
11135
11135
  startDate,
11136
11136
  viewMode,
11137
11137
  columnWidth
11138
11138
  );
11139
- const milestoneHalfWidth = 6;
11140
- return milestonePosition + milestoneHalfWidth;
11139
+ const taskHeight = 32;
11140
+ const milestoneRightEdge = milestoneCenter + taskHeight * 0.5;
11141
+ return milestoneRightEdge;
11141
11142
  };
11142
11143
  const GanttTodayInner = ({
11143
11144
  additionalLeftSpace,
@@ -11,4 +11,8 @@ export interface DataDatePositionOptions {
11
11
  * Calculate data date line position by creating a virtual milestone bar for the data date
12
12
  * and positioning the line at the end of that milestone bar (just like the custom frontend fix)
13
13
  */
14
+ /**
15
+ * Calculate data date line position by positioning it at the right edge of where a milestone
16
+ * would be positioned (exactly matching the actual milestone positioning logic)
17
+ */
14
18
  export declare const calculateDataDatePosition: ({ dataDate, startDate, viewMode, columnWidth, }: DataDatePositionOptions) => number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gantt-task-react-v",
3
- "version": "1.2.10",
3
+ "version": "1.2.11",
4
4
  "description": "Interactive Gantt Chart for React with TypeScript.",
5
5
  "author": "aguilanbon",
6
6
  "homepage": "https://github.com/aguilanbon/gantt-task-react-v",