@etsoo/materialui 1.5.1 → 1.5.2

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.
@@ -40,6 +40,9 @@ function GridDataFormat(data, type, renderProps) {
40
40
  else
41
41
  return shared_1.NumberUtils.format(data, renderProps?.culture, renderProps?.numberFormatOptions);
42
42
  }
43
+ // Array
44
+ if (Array.isArray(data))
45
+ return data.join(", ");
43
46
  if (typeof data === "string")
44
47
  return data;
45
48
  return `${data}`;
@@ -21,6 +21,8 @@ function formatItemData(app, fieldData) {
21
21
  return fieldData;
22
22
  if (fieldData instanceof Date)
23
23
  return app.formatDate(fieldData, "d");
24
+ if (Array.isArray(fieldData))
25
+ return fieldData.join(", ");
24
26
  return `${fieldData}`;
25
27
  }
26
28
  function getResp(singleRow) {
@@ -37,6 +37,9 @@ export function GridDataFormat(data, type, renderProps) {
37
37
  else
38
38
  return NumberUtils.format(data, renderProps?.culture, renderProps?.numberFormatOptions);
39
39
  }
40
+ // Array
41
+ if (Array.isArray(data))
42
+ return data.join(", ");
40
43
  if (typeof data === "string")
41
44
  return data;
42
45
  return `${data}`;
@@ -13,6 +13,8 @@ function formatItemData(app, fieldData) {
13
13
  return fieldData;
14
14
  if (fieldData instanceof Date)
15
15
  return app.formatDate(fieldData, "d");
16
+ if (Array.isArray(fieldData))
17
+ return fieldData.join(", ");
16
18
  return `${fieldData}`;
17
19
  }
18
20
  function getResp(singleRow) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/materialui",
3
- "version": "1.5.1",
3
+ "version": "1.5.2",
4
4
  "description": "TypeScript Material-UI Implementation",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/mjs/index.js",
@@ -71,6 +71,9 @@ export function GridDataFormat(
71
71
  );
72
72
  }
73
73
 
74
+ // Array
75
+ if (Array.isArray(data)) return data.join(", ");
76
+
74
77
  if (typeof data === "string") return data;
75
78
 
76
79
  return `${data}`;
@@ -14,6 +14,7 @@ function formatItemData(
14
14
  if (fieldData == null) return undefined;
15
15
  if (typeof fieldData === "string") return fieldData;
16
16
  if (fieldData instanceof Date) return app.formatDate(fieldData, "d");
17
+ if (Array.isArray(fieldData)) return fieldData.join(", ");
17
18
  return `${fieldData}`;
18
19
  }
19
20