pqina / filepond

🌊 A flexible and fun JavaScript file upload library
https://pqina.nl/filepond
MIT License
15.07k stars 821 forks source link

[Feature] Drop Label Optional #1000

Open hn1 opened 1 week ago

hn1 commented 1 week ago

Is there an existing issue for this?

Is your feature request related to a problem? Please describe.

The Drop label interferes with a lot of UI issues if one wants to create a custom upload with Filepond

Describe the solution you'd like

Make the Drop Label an optional feature which can be removed without affecting the layout

Describe alternatives you've considered

Just that it would be nicw the Drop Label can be removed.

rikschennink commented 1 week ago

I'm not sure what you mean, but if you want to hide the drop label but retain its domrect you could try setting visibility:hidden or opacity:0 on the .filepond--drop-label element with CSS.

hn1 commented 1 week ago

Hi-thanks for responding. If you set the visibility, then the label still takes up space and messes with the layout. If you set display:none, when you remove added files, other elements in Filepond overlap with other elements below it messing up the layout.

The only way we could manage to do it was :

.filepond--panel-root {

 background: none !important;
 /* display:none !important */

}

.filepond--drop-label { display:none !important }

I thought it would be nicer if there was just a flag that one could set. But the above works. Thanks

On Wed, Sep 4, 2024 at 8:37 AM Rik @.***> wrote:

I'm not sure what you mean, but if you want to hide the drop label but retain its domrect you could try setting visibility:hidden or opacity:0 on the .filepond--drop-label element with CSS.

— Reply to this email directly, view it on GitHub https://github.com/pqina/filepond/issues/1000#issuecomment-2328134336, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACA6J2NJB2J2FO7DNO7XLW3ZU22B5AVCNFSM6AAAAABNS557H2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMRYGEZTIMZTGY . You are receiving this because you authored the thread.Message ID: @.***>

viyic commented 1 week ago

I recently needed a way to hide the drop label and its domrect and the way I do it is by adding this CSS. It kind of messes up the animation a bit I think but it works fine.

.filepond--drop-label {
    min-height: 16px !important;
}

.filepond--drop-label * {
    display: none;
}
hn1 commented 1 week ago

Thanks. I tried this way and it works as well:

 .filepond--panel-root {
     background: none !important;
 }

  .filepond--drop-label {
    display:none !important
 }

All in all, it would be nicer if we had an intrinsic solution within Filepond.