@applica-software-guru/react-admin 1.5.291 → 1.5.293

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.
package/package.json CHANGED
@@ -106,5 +106,5 @@
106
106
  "type": "module",
107
107
  "types": "dist/index.d.ts",
108
108
  "typings": "dist/index.d.ts",
109
- "version": "1.5.291"
109
+ "version": "1.5.293"
110
110
  }
@@ -54,7 +54,8 @@ function RawTableFormIterator(props: TableFormIteratorProps): ReactElement | nul
54
54
  empty,
55
55
  template = {},
56
56
  addButton = <AddTableRow />,
57
- inset
57
+ inset,
58
+ sx
58
59
  } = props;
59
60
  const [confirmIsOpen, setConfirmIsOpen] = useState<boolean>(false);
60
61
  const { fields, remove, replace, append } = useArrayInput(props);
@@ -143,6 +144,17 @@ function RawTableFormIterator(props: TableFormIteratorProps): ReactElement | nul
143
144
  // @ts-ignore
144
145
  const tableBorderColor = theme.palette.mode === 'dark' ? theme.palette.grey.A400 : theme.palette.grey.A800;
145
146
  const showClearAllButton = fields.length > 0 && enableClearAll;
147
+ const basicStyles =
148
+ inset === true
149
+ ? {
150
+ borderRadius: 0
151
+ }
152
+ : {
153
+ mt: 2,
154
+ border: `1px solid ${tableBorderColor}`,
155
+ //@ts-ignore
156
+ boxShadow: theme.customShadows.z0
157
+ };
146
158
 
147
159
  return fields ? (
148
160
  // @ts-ignore
@@ -162,13 +174,12 @@ function RawTableFormIterator(props: TableFormIteratorProps): ReactElement | nul
162
174
 
163
175
  <TableContainer
164
176
  component={Paper}
165
- sx={
166
- inset === true
167
- ? {
168
- borderRadius: 0
169
- }
170
- : { mt: 2, border: `1px solid ${tableBorderColor}` }
171
- }
177
+ sx={{
178
+ ...basicStyles,
179
+ //@ts-ignore
180
+ boxShadow: theme.customShadows.z0,
181
+ ...sx
182
+ }}
172
183
  >
173
184
  <Table size="small">
174
185
  <TableHead sx={inset === true ? {} : { borderTop: 0, borderBottom: `1px solid ${tableBorderColor}` }}>
@@ -233,7 +244,7 @@ function RawTableFormIterator(props: TableFormIteratorProps): ReactElement | nul
233
244
 
234
245
  {fields.length > 0 &&
235
246
  fields.map((member: any, index: number) => (
236
- <TableRow sx={{ borderBottom: `1px solid ${tableBorderColor}}` }} key={member.id}>
247
+ <TableRow sx={{ borderBottom: 0 }} key={member.id}>
237
248
  <TableFormIteratorItem
238
249
  disableRemove={disableRemove}
239
250
  index={index}