Validate GLB file mime type

Hello,

I have a form, which has a file upload field. I am trying to restrict that file upload field to only accept GLB files (GLB is a kind of 3D File format). It has a mimetype of "model/gltf-binary", but Filament Forms is not having it when I try to upload an example file.

My code for that field:
FileUpload::make('file')
  ->required()->acceptedFileTypes([
    'model/gltf-binary',
  ])
  ->helperText('Acceptable 3D file types: GLB.'),


What actually happens is then shown in the image attached.
Screenshot_2023-08-11_at_10.37.31_AM.png
Was this page helpful?