diff --git a/src/component/Admin/FileSystem/CustomProps/EditPropsDialog.tsx b/src/component/Admin/FileSystem/CustomProps/EditPropsDialog.tsx index 48e644da2..0945813b1 100644 --- a/src/component/Admin/FileSystem/CustomProps/EditPropsDialog.tsx +++ b/src/component/Admin/FileSystem/CustomProps/EditPropsDialog.tsx @@ -119,7 +119,7 @@ const EditPropsDialog = ({ open, onClose, onSave, isNew, props }: EditPropsDialo setEditProps({ ...editProps, min: parseInt(e.target.value) } as CustomProps)} + onChange={(e) => setEditProps({ ...editProps, min: e.target.value === "" ? undefined : parseInt(e.target.value) } as CustomProps)} /> {fieldType.minDes && {t(fieldType.minDes)}} @@ -132,7 +132,7 @@ const EditPropsDialog = ({ open, onClose, onSave, isNew, props }: EditPropsDialo type="number" required={fieldType.maxRequired} value={editProps?.max || ""} - onChange={(e) => setEditProps({ ...editProps, max: parseInt(e.target.value) } as CustomProps)} + onChange={(e) => setEditProps({ ...editProps, max: e.target.value === "" ? undefined : parseInt(e.target.value) } as CustomProps)} /> {fieldType.maxDes && {t(fieldType.maxDes)}}