You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Guessing it's still in the form state just not in the FileField.
Wondering if it's a controlled input state thing or we force radix to keep the inputs mounted.
The text was updated successfully, but these errors were encountered:
benjaminleonard
changed the title
userData iploaded file disappears when accordion is closeduserData uploaded file disappears when accordion is closed
Jan 24, 2024
After some initial testing, forceMount does work – but it does trip up the animation and despite my wrangling, I'm not sure we can have the animation work with CSS alone. In summary:
Force mount keeps all Accordion.Content elements in the DOM. We can't use display: none to hide them because that does not work with animation. We can use visibility: hidden but they still take up space. By adding forwards to the css animation they do stay hidden (in combo with height: 0) but the animation hasn't run on load so the space is still taken until the use clicks on them. The closest I've got is getting the close animation to work – with the animation plus a height and visibility transition – but not open.
Using react-spring here might be easiest.
Alternative we use the File from the form state. Because whilst the input is uncontrolled, we have own little wrapper on top. Unsure if we maintain the link to the file even when the file input itself is detached.
Guessing it's still in the form state just not in the
FileField
.Wondering if it's a controlled input state thing or we force radix to keep the inputs mounted.
The text was updated successfully, but these errors were encountered: