@megha-ui/react 1.2.316 → 1.2.318
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.
|
@@ -578,7 +578,7 @@ const Grid = ({ columns, wrapperClass, updateGridColumns, data, height, sortable
|
|
|
578
578
|
const lastKey = allKeys[allKeys.length - 1];
|
|
579
579
|
data.forEach((item) => {
|
|
580
580
|
const values = allKeys.map((k) => { var _a, _b; return (_b = (_a = item[k]) === null || _a === void 0 ? void 0 : _a.value) !== null && _b !== void 0 ? _b : ""; });
|
|
581
|
-
const compositeValue = values.join("
|
|
581
|
+
const compositeValue = values.join("+");
|
|
582
582
|
const key = compositeValue;
|
|
583
583
|
if (!groupsMap.has(key)) {
|
|
584
584
|
groupsMap.set(key, {
|
|
@@ -622,7 +622,7 @@ const Grid = ({ columns, wrapperClass, updateGridColumns, data, height, sortable
|
|
|
622
622
|
let allKeysForLevel = undefined;
|
|
623
623
|
if (levelKeys.length > 1) {
|
|
624
624
|
const values = levelKeys.map((k) => { var _a, _b; return (_b = (_a = item[k]) === null || _a === void 0 ? void 0 : _a.value) !== null && _b !== void 0 ? _b : ""; });
|
|
625
|
-
groupValue = values.join("
|
|
625
|
+
groupValue = values.join("+");
|
|
626
626
|
allKeysForLevel = levelKeys;
|
|
627
627
|
}
|
|
628
628
|
else {
|
|
@@ -44,6 +44,7 @@ const GroupedGrid = ({ groupedData, rowOpened, startIndex, endIndex, alternateRo
|
|
|
44
44
|
})
|
|
45
45
|
.map((item, gIndex) => {
|
|
46
46
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
47
|
+
console.log({ item });
|
|
47
48
|
if (gIndex >= startIndex && gIndex <= endIndex)
|
|
48
49
|
return item.type === "main" ? (_jsxs("div", { style: {
|
|
49
50
|
width: "100%",
|
|
@@ -89,7 +90,6 @@ const GroupedGrid = ({ groupedData, rowOpened, startIndex, endIndex, alternateRo
|
|
|
89
90
|
: "+" }), showCount && (_jsx("div", { children: (() => {
|
|
90
91
|
const keys = (item.groupedKey || "").split(">");
|
|
91
92
|
const vals = (item.groupedValue || "").split(">");
|
|
92
|
-
console.log({ vals, item });
|
|
93
93
|
const idx = keys.indexOf(columnKey);
|
|
94
94
|
const display = idx > -1 ? vals[idx] : "";
|
|
95
95
|
return `${display} (${item === null || item === void 0 ? void 0 : item.count})`;
|
package/package.json
CHANGED