pace-table-lib 1.0.68 → 1.0.69
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.
|
@@ -17416,6 +17416,13 @@ function StaticTable({
|
|
|
17416
17416
|
const outsideBorder = isOutsideBorderVisible ? createBorder(Border.LineWidth, Border.LineStyle, Border.LineColor) : null;
|
|
17417
17417
|
const insideVBorder = isInsideVerticalBVisible ? createBorder(Border.VerticalBorderLineWidth, Border.VerticalBorderLineStyle, Border.VerticalBorderLineColor) : null;
|
|
17418
17418
|
const insideHBorder = isInsideHorizontalBVisible ? createBorder(Border.HorizontalBorderLineWidth, Border.HorizontalBorderLineStyle, Border.HorizontalBorderLineColor) : null;
|
|
17419
|
+
const {
|
|
17420
|
+
ShowHeatMap,
|
|
17421
|
+
HeatMapView,
|
|
17422
|
+
HeatMapMinColor,
|
|
17423
|
+
HeatMapMaxColor
|
|
17424
|
+
} = HeatMap || {};
|
|
17425
|
+
const gridRef = useRef(null);
|
|
17419
17426
|
const renderDataCell = (label, styles, className, childClassName, toolTip, dataBarBg) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
17420
17427
|
"div",
|
|
17421
17428
|
{
|
|
@@ -17428,11 +17435,13 @@ function StaticTable({
|
|
|
17428
17435
|
className: `${childClassName} cell_inner`,
|
|
17429
17436
|
style: {
|
|
17430
17437
|
fontFamily: styles.fontFamily,
|
|
17431
|
-
background: dataBarBg ?? "none"
|
|
17438
|
+
background: dataBarBg ?? "none",
|
|
17439
|
+
//Show icon only then align icon to center
|
|
17440
|
+
...styles?.iconPosition === ICON_POSITION.OIcon ? { justifyContent: "center" } : {}
|
|
17432
17441
|
},
|
|
17433
17442
|
children: [
|
|
17434
17443
|
styles && styles?.iconPosition === ICON_POSITION.Left && styles?.iconUrl && /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: styles?.iconUrl, className: "cell_icon left" }),
|
|
17435
|
-
styles && styles?.iconPosition === ICON_POSITION.OIcon && styles?.iconUrl ? /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: styles?.iconUrl, className: "cell_icon
|
|
17444
|
+
styles && styles?.iconPosition === ICON_POSITION.OIcon && styles?.iconUrl ? /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: styles?.iconUrl, className: "cell_icon" }) : /* @__PURE__ */ jsxRuntimeExports.jsx("span", { style: { textAlign: styles.justifyContent }, className: "cell_text", children: label }),
|
|
17436
17445
|
styles && styles?.iconPosition === ICON_POSITION.Right && styles?.iconUrl && /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: styles?.iconUrl, className: "cell_icon right" })
|
|
17437
17446
|
]
|
|
17438
17447
|
}
|
|
@@ -17479,12 +17488,6 @@ function StaticTable({
|
|
|
17479
17488
|
color: DataFieldColor,
|
|
17480
17489
|
...getFontStyleObj(DataFieldFontStyle)
|
|
17481
17490
|
}), [DataField]);
|
|
17482
|
-
const {
|
|
17483
|
-
ShowHeatMap,
|
|
17484
|
-
HeatMapView,
|
|
17485
|
-
HeatMapMinColor,
|
|
17486
|
-
HeatMapMaxColor
|
|
17487
|
-
} = HeatMap || {};
|
|
17488
17491
|
const fixedRowCount = useMemo(() => {
|
|
17489
17492
|
if (!isColHeaderVisible) {
|
|
17490
17493
|
return headerAtStart && isColTotalOn ? 1 : 0;
|
|
@@ -17592,7 +17595,6 @@ function StaticTable({
|
|
|
17592
17595
|
Table2.TableWidth,
|
|
17593
17596
|
Table2.FixHeaderWidth
|
|
17594
17597
|
]);
|
|
17595
|
-
const gridRef = useRef(null);
|
|
17596
17598
|
useEffect(() => {
|
|
17597
17599
|
const t = setTimeout(() => {
|
|
17598
17600
|
if (gridRef.current) {
|
|
@@ -18254,7 +18256,7 @@ function StaticTable({
|
|
|
18254
18256
|
top: fixedRowCount * rowCellHeight + rowIdx * rowCellHeight,
|
|
18255
18257
|
// directly under headers
|
|
18256
18258
|
left: sparkColIndex * fixedColWidth,
|
|
18257
|
-
background:
|
|
18259
|
+
background: rowHeaderBandColorMap[item.sliceMark[0]],
|
|
18258
18260
|
display: "flex",
|
|
18259
18261
|
justifyContent: "center",
|
|
18260
18262
|
alignItems: "center"
|
|
@@ -18412,10 +18414,12 @@ function StaticTable({
|
|
|
18412
18414
|
if (operator === "duplicate") {
|
|
18413
18415
|
const currentVal = value?.toLowerCase();
|
|
18414
18416
|
if (type === CONDITIONAL_FORMAT_FOR.ROW) {
|
|
18415
|
-
const
|
|
18416
|
-
|
|
18417
|
+
const marks = measuresBySlice.map((m) => m.sliceMark);
|
|
18418
|
+
const renderedValues = measuresBySlice.map((item, i) => isFirstOccurrence(marks, i, level) ? item.sliceMark[level]?.toLowerCase() : null).filter((v) => v !== null && v !== void 0);
|
|
18419
|
+
return renderedValues.filter((v) => v === currentVal).length > 1;
|
|
18417
18420
|
} else if (type === CONDITIONAL_FORMAT_FOR.COLUMN) {
|
|
18418
|
-
|
|
18421
|
+
const renderedValues = dimensionMarks.map((d, i) => isFirstOccurrence(dimensionMarks, i, level) ? d[level]?.toLowerCase() : null).filter((v) => v !== null && v !== void 0);
|
|
18422
|
+
return renderedValues.filter((v) => v === currentVal).length > 1;
|
|
18419
18423
|
}
|
|
18420
18424
|
}
|
|
18421
18425
|
if (type === CONDITIONAL_FORMAT_FOR.VALUE) {
|
|
@@ -19961,6 +19965,7 @@ const PivotTable = ({
|
|
|
19961
19965
|
}
|
|
19962
19966
|
}
|
|
19963
19967
|
let percentage = 0;
|
|
19968
|
+
let kpiColor = "";
|
|
19964
19969
|
if (KPI.KPIVisibility) {
|
|
19965
19970
|
const baseType = tableStyleProps.KPI.KPIBaseFormat;
|
|
19966
19971
|
const values = baseType === "Column-wise" ? flatRows?.map(
|
|
@@ -19977,7 +19982,7 @@ const PivotTable = ({
|
|
|
19977
19982
|
0,
|
|
19978
19983
|
Math.min(100, (Number(rawValue) - min) / (max - min) * 100)
|
|
19979
19984
|
) : 0;
|
|
19980
|
-
interpolateColor(
|
|
19985
|
+
kpiColor = interpolateColor(
|
|
19981
19986
|
KPI.KPIMinColor,
|
|
19982
19987
|
KPI.KPIMaxColor,
|
|
19983
19988
|
percentage / 100
|
|
@@ -20020,7 +20025,7 @@ const PivotTable = ({
|
|
|
20020
20025
|
"div",
|
|
20021
20026
|
{
|
|
20022
20027
|
className: "kpi-wrapper cell_inner_pivot",
|
|
20023
|
-
style: { justifyContent: dataCellFont.justifyContent },
|
|
20028
|
+
style: { justifyContent: dataCellFont.justifyContent, background: kpiColor ?? "none" },
|
|
20024
20029
|
children: [
|
|
20025
20030
|
conditionalFormatObj && conditionalFormatObj?.iconPosition === ICON_POSITION.Left && conditionalFormatObj?.iconUrl && /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: conditionalFormatObj?.iconUrl, className: "cell_icon_pivot left" }),
|
|
20026
20031
|
conditionalFormatObj && conditionalFormatObj?.iconPosition === ICON_POSITION.OIcon && conditionalFormatObj?.iconUrl ? /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: conditionalFormatObj?.iconUrl, className: "cell_icon_pivot left" }) : /* @__PURE__ */ jsxRuntimeExports.jsx("span", { style: { textAlign: dataCellFont.justifyContent, ...shouldWrap ? { wordBreak: "break-word", whiteSpace: "normal" } : { whiteSpace: "nowrap", overflow: "hidden", textOverflow: "ellipsis" } }, className: "kpi-text cell_text_pivot_pivot", children: formattedValue }),
|