willmcpo / body-scroll-lock

Body scroll locking that just works with everything 😏
MIT License
4.05k stars 339 forks source link

Doesn't work on Android webview #84

Open Bobgy opened 5 years ago

Bobgy commented 5 years ago

I've tried this and it works on almost everywhere except Android webview.

I don't quite understand why it could be different between chrome 70 in browser vs chrome 70 in webview, but I am seeing this issue.

Current Behavior in Android webview: when you scroll the scrollable overlay to one end, then it starts to scroll body instead. Expected Behavior in Android webview: when you scroll the scrollable overlay to one end, then it stops there without doing anything else.

Note that in Android Chrome, it behaves as expected.

GulinSS commented 5 years ago

Same for me

ml-andy commented 5 years ago

Same for me

manuel140 commented 5 years ago

Same for me

hoyangtsai commented 5 years ago

same here

BuptStEve commented 5 years ago

hey guys, how about trying this https://github.com/tuateam/tua-body-scroll-lock

zhangciwu commented 5 years ago

@Bobgy it works. But I think this is a bug of Android webview, maybe there is a bug report of that project?

eugeneoshepkov commented 5 years ago

Same problem, doesn't work in webview

juliocbgomes commented 2 years ago

I had this same problem developing a webview with Angular. I needed to create a list of cards in a horizontal scroll and for some reason it wasn't working.

Strangely this line of code solved my problem, even though it did "nothing".

ngAfterViewInit(){ fromEvent(this.scrollElement, 'touchend').pipe(takeUntil(this.unsubscribe$)).subscribe(); }