gantt-task-react-v 1.7.4 → 1.7.6
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.
|
@@ -5703,7 +5703,8 @@ const TaskListTableHeadersDefaultInner = ({
|
|
|
5703
5703
|
position: "sticky",
|
|
5704
5704
|
left: leftOffset,
|
|
5705
5705
|
zIndex: 2,
|
|
5706
|
-
backgroundColor: "var(--gantt-table-header-background-color, #fff)"
|
|
5706
|
+
backgroundColor: "var(--gantt-table-header-background-color, #fff)",
|
|
5707
|
+
paddingRight: 8
|
|
5707
5708
|
};
|
|
5708
5709
|
leftOffset += columns[i].width;
|
|
5709
5710
|
}
|
|
@@ -5715,7 +5716,8 @@ const TaskListTableHeadersDefaultInner = ({
|
|
|
5715
5716
|
position: "sticky",
|
|
5716
5717
|
right: rightOffset,
|
|
5717
5718
|
zIndex: 2,
|
|
5718
|
-
backgroundColor: "var(--gantt-table-header-background-color, #fff)"
|
|
5719
|
+
backgroundColor: "var(--gantt-table-header-background-color, #fff)",
|
|
5720
|
+
paddingLeft: 8
|
|
5719
5721
|
};
|
|
5720
5722
|
rightOffset += columns[i].width;
|
|
5721
5723
|
}
|
|
@@ -10475,13 +10477,21 @@ const TaskListTableRowInner = forwardRef(
|
|
|
10475
10477
|
}, [isCut2, moveOverPosition, isOverlay2, isDragging]);
|
|
10476
10478
|
const pinnedStyles = useMemo(() => {
|
|
10477
10479
|
const result = {};
|
|
10480
|
+
const pinnedBg = backgroundColor || "var(--gantt-background-color, #fff)";
|
|
10478
10481
|
for (let i = 0; i < columns.length; i++) {
|
|
10479
10482
|
if (columns[i].pinned === "left") {
|
|
10480
10483
|
result[i] = {
|
|
10481
10484
|
position: "relative",
|
|
10482
10485
|
transform: "translateX(var(--pinned-translate-left, 0px))",
|
|
10483
10486
|
zIndex: 2,
|
|
10484
|
-
backgroundColor:
|
|
10487
|
+
backgroundColor: pinnedBg,
|
|
10488
|
+
// box-shadow + clip-path create a bulletproof opaque cover that
|
|
10489
|
+
// extends 10px past the cell's right edge, hiding any content
|
|
10490
|
+
// that scrolls underneath. clip-path trims the shadow to
|
|
10491
|
+
// exactly the cell bounds plus the 10px overhang.
|
|
10492
|
+
boxShadow: `0 0 0 9999px ${pinnedBg}`,
|
|
10493
|
+
clipPath: "inset(0px -10px 0px 0px)",
|
|
10494
|
+
paddingRight: 10
|
|
10485
10495
|
};
|
|
10486
10496
|
}
|
|
10487
10497
|
}
|
|
@@ -10491,12 +10501,15 @@ const TaskListTableRowInner = forwardRef(
|
|
|
10491
10501
|
position: "relative",
|
|
10492
10502
|
transform: "translateX(var(--pinned-translate-right, 0px))",
|
|
10493
10503
|
zIndex: 2,
|
|
10494
|
-
backgroundColor:
|
|
10504
|
+
backgroundColor: pinnedBg,
|
|
10505
|
+
boxShadow: `0 0 0 9999px ${pinnedBg}`,
|
|
10506
|
+
clipPath: "inset(0px 0px 0px -10px)",
|
|
10507
|
+
paddingLeft: 10
|
|
10495
10508
|
};
|
|
10496
10509
|
}
|
|
10497
10510
|
}
|
|
10498
10511
|
return result;
|
|
10499
|
-
}, [columns]);
|
|
10512
|
+
}, [columns, backgroundColor]);
|
|
10500
10513
|
return /* @__PURE__ */ jsxs(
|
|
10501
10514
|
"div",
|
|
10502
10515
|
{
|
|
@@ -5720,7 +5720,8 @@
|
|
|
5720
5720
|
position: "sticky",
|
|
5721
5721
|
left: leftOffset,
|
|
5722
5722
|
zIndex: 2,
|
|
5723
|
-
backgroundColor: "var(--gantt-table-header-background-color, #fff)"
|
|
5723
|
+
backgroundColor: "var(--gantt-table-header-background-color, #fff)",
|
|
5724
|
+
paddingRight: 8
|
|
5724
5725
|
};
|
|
5725
5726
|
leftOffset += columns[i].width;
|
|
5726
5727
|
}
|
|
@@ -5732,7 +5733,8 @@
|
|
|
5732
5733
|
position: "sticky",
|
|
5733
5734
|
right: rightOffset,
|
|
5734
5735
|
zIndex: 2,
|
|
5735
|
-
backgroundColor: "var(--gantt-table-header-background-color, #fff)"
|
|
5736
|
+
backgroundColor: "var(--gantt-table-header-background-color, #fff)",
|
|
5737
|
+
paddingLeft: 8
|
|
5736
5738
|
};
|
|
5737
5739
|
rightOffset += columns[i].width;
|
|
5738
5740
|
}
|
|
@@ -10492,13 +10494,21 @@
|
|
|
10492
10494
|
}, [isCut2, moveOverPosition, isOverlay2, isDragging]);
|
|
10493
10495
|
const pinnedStyles = React.useMemo(() => {
|
|
10494
10496
|
const result = {};
|
|
10497
|
+
const pinnedBg = backgroundColor || "var(--gantt-background-color, #fff)";
|
|
10495
10498
|
for (let i = 0; i < columns.length; i++) {
|
|
10496
10499
|
if (columns[i].pinned === "left") {
|
|
10497
10500
|
result[i] = {
|
|
10498
10501
|
position: "relative",
|
|
10499
10502
|
transform: "translateX(var(--pinned-translate-left, 0px))",
|
|
10500
10503
|
zIndex: 2,
|
|
10501
|
-
backgroundColor:
|
|
10504
|
+
backgroundColor: pinnedBg,
|
|
10505
|
+
// box-shadow + clip-path create a bulletproof opaque cover that
|
|
10506
|
+
// extends 10px past the cell's right edge, hiding any content
|
|
10507
|
+
// that scrolls underneath. clip-path trims the shadow to
|
|
10508
|
+
// exactly the cell bounds plus the 10px overhang.
|
|
10509
|
+
boxShadow: `0 0 0 9999px ${pinnedBg}`,
|
|
10510
|
+
clipPath: "inset(0px -10px 0px 0px)",
|
|
10511
|
+
paddingRight: 10
|
|
10502
10512
|
};
|
|
10503
10513
|
}
|
|
10504
10514
|
}
|
|
@@ -10508,12 +10518,15 @@
|
|
|
10508
10518
|
position: "relative",
|
|
10509
10519
|
transform: "translateX(var(--pinned-translate-right, 0px))",
|
|
10510
10520
|
zIndex: 2,
|
|
10511
|
-
backgroundColor:
|
|
10521
|
+
backgroundColor: pinnedBg,
|
|
10522
|
+
boxShadow: `0 0 0 9999px ${pinnedBg}`,
|
|
10523
|
+
clipPath: "inset(0px 0px 0px -10px)",
|
|
10524
|
+
paddingLeft: 10
|
|
10512
10525
|
};
|
|
10513
10526
|
}
|
|
10514
10527
|
}
|
|
10515
10528
|
return result;
|
|
10516
|
-
}, [columns]);
|
|
10529
|
+
}, [columns, backgroundColor]);
|
|
10517
10530
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10518
10531
|
"div",
|
|
10519
10532
|
{
|
package/package.json
CHANGED