react-admin icon indicating copy to clipboard operation
react-admin copied to clipboard

FileInput does not display error on validation error

Open natrim opened this issue 9 years ago • 5 comments

ie. when i put required on FileInput <FileInput source="files" label="common.file" accept={allowedFiles} validate={[required]}> <RestedFileField source="url" title="name" /> </FileInput>

the form is not sent but does not display any error

(same with ImageInput)

natrim avatar Jul 04 '17 12:07 natrim

Is this bug back? I seem to be having a similar issue; the form does not send but there is no displayed error message. Looking at the changes for #949 the errorText in Labeled.js seems to have been removed at some point.

quicklikerabbit avatar Jan 09 '18 19:01 quicklikerabbit

Having the same issue. Also should this even work for the maxSize prop? Or do I have to find another way of displaying that the selected file is too large?

nik-lampe avatar Jan 14 '18 15:01 nik-lampe

Having this issue too, it looks like meta or similar is not being passed around correctly? The validation function runs but the UI doesn't indicate an error (but the form will not submit). On the latest v2.2.2

r9nick avatar Aug 29 '18 22:08 r9nick

This problem is still present in the 2.4.0 version

alexandremottet avatar Nov 20 '18 14:11 alexandremottet

Duplicate of #6441

nosequeldeebee avatar Sep 05 '22 22:09 nosequeldeebee