fix: ArrayField not showing "no rows" when empty

Massimo Melina committed Aug 7, 2023 at 18:56 UTC 3a0804c656b4bf63392aba7d419714882080639d
1 file changed +2
admin/src/ArrayField.ts
+2
@@ -24,6 +24,7 @@ export function ArrayField<T extends object>({ label, helperText, fields, value,
24 h(Box, { ...rest },
25 h(DataGrid, {
26 rows,
27 + sx: { '.MuiDataGrid-virtualScroller': { minHeight: '3em' } },
28 hideFooterSelectedRowCount: true,
29 hideFooter: true,
30 componentsProps: {
@@ -76,6 +77,7 @@ export function ArrayField<T extends object>({ label, helperText, fields, value,
77 h(GridActionsCellItem as any, {
78 icon: h(Edit),
79 label: title,
80 + title,
81 onClick(event: MouseEvent) {
82 formDialog<T>({ values: row as any, form, title }).then(x => {
83 if (x)