Skip to content

Commit

Permalink
FieldGuesser: props passing to SingleFieldList
Browse files Browse the repository at this point in the history
  • Loading branch information
PawelSuwinski committed Feb 13, 2023
1 parent bf00773 commit e50f3a8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/FieldGuesser.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import type {
NumberFieldProps,
ReferenceArrayFieldProps,
ReferenceFieldProps,
SingleFieldListProps,
TextFieldProps,
UrlFieldProps,
} from 'react-admin';
Expand Down Expand Up @@ -69,7 +70,7 @@ const renderField = (
<ReferenceArrayField
{...(props as ReferenceArrayFieldProps)}
reference={field.reference.name}>
<SingleFieldList>
<SingleFieldList {...(props as SingleFieldListProps)}>
<ChipField source={fieldName} key={fieldName} />
</SingleFieldList>
</ReferenceArrayField>
Expand Down
2 changes: 2 additions & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ import type {
ResourceProps,
ShowProps,
SimpleFormProps,
SingleFieldListProps,
TabbedFormProps,
TextFieldProps,
TextInputProps,
Expand Down Expand Up @@ -453,6 +454,7 @@ export type FieldProps =
| EmailFieldProps
| ArrayFieldProps
| ReferenceArrayFieldProps
| SingleFieldListProps
| EnumFieldProps
| ReferenceFieldProps;

Expand Down

0 comments on commit e50f3a8

Please sign in to comment.