Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Full-height sheet with scrollable content & collapsing URL bar (Chrome Android) #17

Open
rsimon opened this issue Aug 22, 2024 · 1 comment
Labels

Comments

@rsimon
Copy link

rsimon commented Aug 22, 2024

I noticed the following issue with scroll behavior (on Chrome Android in my case):

  • If I have a sheet with scrollable content, and I open the sheet to the full screen height, scrolling upwards collapses the browser URL bar.
  • The sheet doesn't catch up with this height change, until after releasing the touch. Instead, the background of the page becomes visibe.
  • After releasing touch, the sheet jumps upwards to fill the new height.

react-spring-bottom-sheet somehow managed to get around this. When scrolling content, it stopped the URL bar from collapsing, I believe by using the body-scroll-lock library. I tried reproducing this approach, but couldn't get it to work.

I'm wondering if you have any thoughts on/if it's possible to prevent the URL bar from collapsing when scrolling upwards on full-height sheet, thus avoiding the nasty jumping effect?

Thanks!

@woofers woofers added the triage label Aug 23, 2024
@woofers
Copy link
Owner

woofers commented Aug 23, 2024

Hi @rsimon, react-sheet-slide also uses a fork of body-scroll-lock, I'm not sure if there is a way to avoid the mobile web browser behaviour of having the address bar show and hide. Certain factors on the page can influence if it occurs but as it stands there is not a lot of public documentation around how Chrome and Safari handle this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants