Temzasse / react-modal-sheet

Flexible bottom sheet component built with Framer Motion to provide buttery smooth UX while keeping accessibility in mind 🪐

Home Page:https://temzasse.github.io/react-modal-sheet/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Close the sheet, but the component remains mounted with opacity 0.

jafelixeducaria opened this issue · comments

Hello.

Under normal operation, when the sheet is closed, its internal components, such as the divs with classes 'react-modal-sheet-container' and 'react-modal-sheet-content', along with other internal components, disappear, causing the main sheet to take on the 'hidden' class.

However, in some instances, when the sheet is closed, it takes on the 'hidden' class but still retains the aforementioned internal components. In this case, the sheet closes, but the internal components remain mounted with opacity set to 0, causing the application to freeze since there is a layer above that is blocking the rest of the functionality.

Best regards.

Hi @jafelixeducaria 👋🏻

Unfortunately without a reproduction this is very difficult to fix.

I've added some tolerance to various value comparisons to avoid situations like this. Try updating to the latest version and hopefully that will help 🙂