bilogic / bilogic.github.io

0 stars 0 forks source link

Filepond / Filament - Fileupload captions #1

Open svendehens opened 10 months ago

svendehens commented 10 months ago

Hi, by coincidence I've seen you asking a similar question about adding captions to the file uploads in Filament as you had. At least, the times I've been looking for answers it seems you had already asked them before. I was wondering if you ever figured out how to make something work? I'd be looking to be able to implement a way to add a simple caption to files uploaded in filament using the Spatie Media Library Plugin. Thanks in advance, Sven

bilogic commented 10 months ago

@svendehens

Thanks for your interest.

I already got it working, except not in the way the maintainer wants it.

See https://github.com/filamentphp/filament/pull/8381 for specific details on what needs to be changed.

Unfortunately, I have 0 bandwidth to take on this at the moment, but I can address any questions you might have about the implementation.

svendehens commented 10 months ago

Hi, yes this thread was one I had already been looking at. Would you mind sharing how you ended up implementing it?

bilogic commented 10 months ago

The changes are in the commits, are you familiar?

bilogic commented 10 months ago

image

The entire change can be found in these 4 commits, the rest are just formatting and merges which are unrelated

svendehens commented 10 months ago

Ok, got it! I ended up going about it in another way. I made a form section that includes the SpatieMediaLibraryFileUpload with a header action to add the custom properties in the modal. So far it works quite well in terms of UI/UX. Thanks for yr responses

bilogic commented 10 months ago

Ideally, we want these changes pushed into Filament itself, otherwise you will have to rebase these changes each time Filament makes a release