gantt-task-react-powern 0.6.12 → 0.6.14
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.
- package/dist/index.js +41 -32
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +41 -32
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -3136,6 +3136,8 @@ var Gantt = function Gantt(_ref) {
|
|
|
3136
3136
|
isProcessing = _useState15[0],
|
|
3137
3137
|
setIsProcessing = _useState15[1];
|
|
3138
3138
|
|
|
3139
|
+
var processCounter = useRef(0);
|
|
3140
|
+
var performanceRef = useRef(performance.now());
|
|
3139
3141
|
var buffer = rowHeight * 10;
|
|
3140
3142
|
var visibleStartY = scrollY - buffer;
|
|
3141
3143
|
var visibleEndY = scrollY + ganttHeight + buffer;
|
|
@@ -3152,7 +3154,15 @@ var Gantt = function Gantt(_ref) {
|
|
|
3152
3154
|
clearTimeout(debounceRef.current);
|
|
3153
3155
|
}
|
|
3154
3156
|
|
|
3155
|
-
|
|
3157
|
+
if (performance.now() - performanceRef.current > 3000 && processCounter.current < 2) {
|
|
3158
|
+
processCounter.current += 1;
|
|
3159
|
+
}
|
|
3160
|
+
|
|
3161
|
+
if (processCounter.current <= 2) {
|
|
3162
|
+
setIsProcessing(true);
|
|
3163
|
+
}
|
|
3164
|
+
|
|
3165
|
+
performanceRef.current = performance.now();
|
|
3156
3166
|
debounceRef.current = setTimeout(function () {
|
|
3157
3167
|
var filteredTasks;
|
|
3158
3168
|
filteredTasks = removeHiddenTasks(tasks);
|
|
@@ -3540,37 +3550,11 @@ var Gantt = function Gantt(_ref) {
|
|
|
3540
3550
|
taskLabelRenderer: taskLabelRenderer,
|
|
3541
3551
|
onMultiSelect: onMultiSelect
|
|
3542
3552
|
};
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
position: "relative",
|
|
3549
|
-
minHeight: ganttHeight + 70 || 400
|
|
3550
|
-
}
|
|
3551
|
-
}, React.createElement("div", {
|
|
3552
|
-
style: {
|
|
3553
|
-
position: "absolute",
|
|
3554
|
-
inset: 0,
|
|
3555
|
-
height: "100%",
|
|
3556
|
-
width: "100%",
|
|
3557
|
-
display: "flex",
|
|
3558
|
-
justifyContent: "center",
|
|
3559
|
-
alignItems: "center",
|
|
3560
|
-
gap: "16px"
|
|
3561
|
-
}
|
|
3562
|
-
}, React.createElement("span", {
|
|
3563
|
-
style: {
|
|
3564
|
-
fontSize: "24px",
|
|
3565
|
-
color: "#cc0404",
|
|
3566
|
-
fontFamily: "Arial, sans-serif"
|
|
3567
|
-
}
|
|
3568
|
-
}, "Loading..."), React.createElement("div", {
|
|
3569
|
-
className: styles$9.spinner
|
|
3570
|
-
})));
|
|
3571
|
-
}
|
|
3572
|
-
|
|
3573
|
-
return React.createElement("div", null, React.createElement("div", {
|
|
3553
|
+
return React.createElement("div", {
|
|
3554
|
+
style: {
|
|
3555
|
+
position: "relative"
|
|
3556
|
+
}
|
|
3557
|
+
}, React.createElement("div", {
|
|
3574
3558
|
className: styles$9.wrapper,
|
|
3575
3559
|
onKeyDown: handleKeyDown,
|
|
3576
3560
|
tabIndex: 0,
|
|
@@ -3605,6 +3589,31 @@ var Gantt = function Gantt(_ref) {
|
|
|
3605
3589
|
scroll: scrollY,
|
|
3606
3590
|
onScroll: handleScrollY,
|
|
3607
3591
|
rtl: rtl
|
|
3592
|
+
})), isProcessing && React.createElement("div", {
|
|
3593
|
+
style: {
|
|
3594
|
+
position: "absolute",
|
|
3595
|
+
top: 0,
|
|
3596
|
+
left: 0,
|
|
3597
|
+
right: 0,
|
|
3598
|
+
bottom: 0,
|
|
3599
|
+
backgroundColor: "rgba(255, 255, 255, 0.95)",
|
|
3600
|
+
display: "flex",
|
|
3601
|
+
justifyContent: "center",
|
|
3602
|
+
alignItems: "center",
|
|
3603
|
+
gap: "20px",
|
|
3604
|
+
zIndex: 9999,
|
|
3605
|
+
pointerEvents: "none",
|
|
3606
|
+
borderRadius: "8px"
|
|
3607
|
+
}
|
|
3608
|
+
}, React.createElement("span", {
|
|
3609
|
+
style: {
|
|
3610
|
+
fontSize: "24px",
|
|
3611
|
+
fontWeight: "600",
|
|
3612
|
+
color: "#cc0404",
|
|
3613
|
+
fontFamily: "Arial, sans-serif"
|
|
3614
|
+
}
|
|
3615
|
+
}, "Loading..."), React.createElement("div", {
|
|
3616
|
+
className: styles$9.spinner
|
|
3608
3617
|
})), React.createElement(HorizontalScroll, {
|
|
3609
3618
|
svgWidth: svgWidth,
|
|
3610
3619
|
taskListWidth: taskListWidth,
|