It seems that when specifying rules to a FileUpload field, it is not validated. Is that expected behaviour?
FileUpload::make('csv_file') ->label(__('CSV File')) ->rules(['mimes:csv,txt']) // This allows images just fine
FileUpload::make('csv_file') ->label(__('CSV File')) ->rules(['mimes:csv,txt']) // This allows images just fine
I know I probably should use
->acceptedFileTypes()
->acceptedFileTypes()
for this, but I actually want to validate the input on WOFF and WOFF2 font files. Since acceptedFileTypes uses the front-end validator of Filepond, I can't use this, because browsers cannot resolve the correct mimetypes for these files...
So, I need to do some serverside validation. But how?
Description This PR adds better front-end filetype validation to the FileUpload field. The FileUpload field uses Filepond for uploading files. When setting ->acceptedFileTypes() with the accepte...