We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents add7a37 + 64a7f87 commit 6738816Copy full SHA for 6738816
src/components/tables/CellTable.jsx
@@ -28,17 +28,18 @@ export default function cellTable(
28
) {
29
columnProp = Object.keys(columnProp).map((key) => {
30
return {
31
- [key]: columnProp[key],
32
- }
33
- })
34
35
-
36
- if (Array.isArray(columnProp) && typeof columnProp[0] !== 'object') {
37
- columnProp = columnProp.map((row) => {
38
- return {
39
- Value: row,
+ Key: key,
+ Value: columnProp[key],
40
}
41
})
+ } else {
+ if (Array.isArray(columnProp) && typeof columnProp[0] !== 'object') {
+ columnProp = columnProp.map((row) => {
+ return {
+ Value: row,
+ }
+ })
42
43
44
45
const handleTable = ({ columnProp }) => {
0 commit comments