@megha-ui/react 1.2.317 → 1.2.319

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.
@@ -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%",
@@ -54,9 +55,7 @@ const GroupedGrid = ({ groupedData, rowOpened, startIndex, endIndex, alternateRo
54
55
  boxSizing: "border-box", // Include padding and borders in the element's total width and height
55
56
  backgroundColor: "var(--summary-bg)",
56
57
  }, onClick: () => updateRowOpened(item.groupedValue), children: [(_a = item.groupedKey) === null || _a === void 0 ? void 0 : _a.split(">").map((columnKey, index) => {
57
- var _a;
58
58
  const column = gridColumns.find((column) => column.key === columnKey);
59
- const showCount = ((_a = item.groupedKey) === null || _a === void 0 ? void 0 : _a.split(">").length) - 1 === index;
60
59
  if (column) {
61
60
  return (_jsxs("div", { style: {
62
61
  width: widthMode === "auto"
@@ -86,13 +85,15 @@ const GroupedGrid = ({ groupedData, rowOpened, startIndex, endIndex, alternateRo
86
85
  justifyContent: "center",
87
86
  }, children: rowOpened.includes(item.groupedValue || "")
88
87
  ? "-"
89
- : "+" }), showCount && (_jsx("div", { children: (() => {
88
+ : "+" }), _jsx("div", { children: (() => {
90
89
  const keys = (item.groupedKey || "").split(">");
91
90
  const vals = (item.groupedValue || "").split(">");
92
91
  const idx = keys.indexOf(columnKey);
93
92
  const display = idx > -1 ? vals[idx] : "";
94
- return `${display} (${item === null || item === void 0 ? void 0 : item.count})`;
95
- })() }))] }));
93
+ if (display) {
94
+ return `${display} (${item === null || item === void 0 ? void 0 : item.count})`;
95
+ }
96
+ })() })] }));
96
97
  }
97
98
  return null;
98
99
  }), isSummarise &&
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@megha-ui/react",
3
- "version": "1.2.317",
3
+ "version": "1.2.319",
4
4
  "description": "A collection of reusable UI components for React applications, built with TypeScript.",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",