diff --git a/src/CreateGuesser.tsx b/src/CreateGuesser.tsx index 77d87543..4faacded 100644 --- a/src/CreateGuesser.tsx +++ b/src/CreateGuesser.tsx @@ -59,6 +59,7 @@ export const IntrospectedCreateGuesser = ({ warnWhenUnsavedChanges, sanitizeEmptyValues = true, formComponent, + viewComponent, children, ...props }: IntrospectedCreateGuesserProps) => { @@ -162,7 +163,7 @@ export const IntrospectedCreateGuesser = ({ const FormType = hasFormTab ? TabbedForm : SimpleForm; return ( - + ) => ({ ...data, extraInformation: { hasFileField }, diff --git a/src/ShowGuesser.tsx b/src/ShowGuesser.tsx index a71cfcbc..bcb99594 100644 --- a/src/ShowGuesser.tsx +++ b/src/ShowGuesser.tsx @@ -44,6 +44,7 @@ export const IntrospectedShowGuesser = ({ writableFields, schema, schemaAnalyzer, + viewComponent, children, ...props }: IntrospectedShowGuesserProps) => { @@ -70,7 +71,7 @@ export const IntrospectedShowGuesser = ({ const ShowLayout = hasTab ? TabbedShowLayout : SimpleShowLayout; return ( - + {fieldChildren} ); diff --git a/src/types.ts b/src/types.ts index 30032f7d..ee519363 100644 --- a/src/types.ts +++ b/src/types.ts @@ -370,6 +370,7 @@ type CreateFormProps = Omit< CreateProps & SimpleFormProps & TabbedFormProps, 'children' > & + Partial> & Partial< PickRename > & { @@ -388,6 +389,7 @@ type EditFormProps = Omit< EditProps & SimpleFormProps & TabbedFormProps, 'children' > & + Partial> & Partial< PickRename > & { @@ -421,9 +423,10 @@ export type ListGuesserProps = Omit< type ShowFormProps = Omit< ShowProps & SimpleFormProps & TabbedFormProps, 'children' -> & { - children?: ReactNode; -}; +> & + Partial> & { + children?: ReactNode; + }; export type IntrospectedShowGuesserProps = ShowFormProps & IntrospectedGuesserProps;