diff --git a/frontend/src/components/content-types/ContentTypeDialog.tsx b/frontend/src/components/content-types/ContentTypeDialog.tsx index 5dd9c0f3..3c248040 100644 --- a/frontend/src/components/content-types/ContentTypeDialog.tsx +++ b/frontend/src/components/content-types/ContentTypeDialog.tsx @@ -25,7 +25,7 @@ import { EntityType } from "@/services/types"; import { ContentFieldType, IContentType } from "@/types/content-type.types"; import { FieldInput } from "./components/FieldInput"; -import { FIELDS_FORM_DEFAULT_VALUES, READ_ONLY_FIELDS } from "./constants"; +import { READ_ONLY_FIELDS } from "./constants"; export type ContentTypeDialogProps = DialogControlProps; export const ContentTypeDialog: FC = ({ @@ -45,7 +45,7 @@ export const ContentTypeDialog: FC = ({ } = useForm>({ defaultValues: { name: data?.name || "", - fields: data?.fields || FIELDS_FORM_DEFAULT_VALUES, + fields: data?.fields || [], }, }); const { append, fields, remove } = useFieldArray({ @@ -90,7 +90,7 @@ export const ContentTypeDialog: FC = ({ if (data) { reset({ name: data.name, - fields: data.fields || FIELDS_FORM_DEFAULT_VALUES, + fields: data.fields || [], }); } else { reset();