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
When preventScroll={true}, I noticed the component adds data-melt-scroll-lock with style="overflow: hidden; padding-right: calc(0px);". However, when I have all transitions functions and configs (see reproduction), the overflow: hidden and data-melt-scroll-lock remains when dialog is closed, so I can't scroll the body anymore.
Without inTransition, inTransitionConfig, outTransition, and outTransitionConfig, when closed, the data-melt-scroll-lock is destroyed.
In my repro example below I uses shallow routing to open the dialog, but I'll try to whip up another simple example - but I still believe it would behave the same.
The text was updated successfully, but these errors were encountered:
syedkhairi
changed the title
Dialog transitions causes data-melt-scroll-lock not to be destroyed
Dialog outTransition, outTransitionConfig causes data-melt-scroll-lock not to be destroyed
May 29, 2024
Describe the bug
When
preventScroll={true}
, I noticed the component addsdata-melt-scroll-lock
withstyle="overflow: hidden; padding-right: calc(0px);"
. However, when I have all transitions functions and configs (see reproduction), theoverflow: hidden
anddata-melt-scroll-lock
remains when dialog is closed, so I can't scroll the body anymore.Without
,inTransition
,inTransitionConfig
outTransition
, andoutTransitionConfig
, when closed, thedata-melt-scroll-lock
is destroyed.In my repro example below I uses shallow routing to open the dialog, but I'll try to whip up another simple example - but I still believe it would behave the same.
Reproduction
https://stackblitz.com/edit/github-3ug31a?file=src%2Flib%2FDialog.svelte
Logs
No response
System Info
Severity
annoyance
The text was updated successfully, but these errors were encountered: