pace-table-lib 1.0.15 → 1.0.17
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.
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
}
|
|
12
12
|
})();
|
|
13
13
|
import * as React from "react";
|
|
14
|
-
import React__default, { cloneElement, useRef, useMemo } from "react";
|
|
14
|
+
import React__default, { cloneElement, useRef, useMemo, useEffect } from "react";
|
|
15
15
|
function getDefaultExportFromCjs(x) {
|
|
16
16
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
17
17
|
}
|
|
@@ -8361,6 +8361,15 @@ function StaticTable({
|
|
|
8361
8361
|
return { cellHeight: Number(dynHeight), cellWidth: Number(dWidth), fixedColWidth: Number(fWidth) };
|
|
8362
8362
|
}, [isFitTableOn, columnCount, rowCount, fixedColCount, tableWidth, tableHeight]);
|
|
8363
8363
|
const gridRef = useRef(null);
|
|
8364
|
+
useEffect(() => {
|
|
8365
|
+
const t = setTimeout(() => {
|
|
8366
|
+
if (gridRef.current) {
|
|
8367
|
+
gridRef.current.recomputeGridSize();
|
|
8368
|
+
gridRef.current.forceUpdateGrids();
|
|
8369
|
+
}
|
|
8370
|
+
}, 0);
|
|
8371
|
+
return () => clearTimeout(t);
|
|
8372
|
+
}, [tableWidth, tableHeight, tableData, isFitTableOn]);
|
|
8364
8373
|
const conditionalFormatsByType = useMemo(() => {
|
|
8365
8374
|
const map = { value: [], "row header": [], "column header": [] };
|
|
8366
8375
|
conditionalFormatArr?.forEach((format) => {
|
|
@@ -8684,7 +8693,7 @@ function StaticTable({
|
|
|
8684
8693
|
const finalStyleForRow = getFinalStyleObj(STYLE_FOR.ROW, baseStyleObj, rowLabel, level, groupIndex);
|
|
8685
8694
|
headers.push({
|
|
8686
8695
|
...finalStyleForRow,
|
|
8687
|
-
label: rowLabel,
|
|
8696
|
+
label: getCleanString(rowLabel),
|
|
8688
8697
|
top: offsetTop,
|
|
8689
8698
|
left: level * fixedColWidth,
|
|
8690
8699
|
width: fixedColWidth,
|