Problem with a Filament Forms Livewire Component with a SpatieMediaLibraryFileUpload field
I've followed this example and created a livewire component with this form:
and the form itself
When user select a file, wait until it is uploaded and then click submit the form work fine. But if a user click the submit button before file has been uploaded it creates a problem. The attachments field is an optional field, so the submit go through, but files are not uploaded in this case.
Does anyone have an idea how to solve this?
In the Filament Panel, they have states for the Submit button to prevent users from clicking Submit while files are loading. Is there any way how to implement this in the livewire component?
Thank you
and the form itself
When user select a file, wait until it is uploaded and then click submit the form work fine. But if a user click the submit button before file has been uploaded it creates a problem. The attachments field is an optional field, so the submit go through, but files are not uploaded in this case.
Does anyone have an idea how to solve this?
In the Filament Panel, they have states for the Submit button to prevent users from clicking Submit while files are loading. Is there any way how to implement this in the livewire component?
Thank you
