Disable overscroll in modals on iOS


#1

I’ve got overscroll disabled on the app using the Cordova settings, but overscroll is still happening in my modals on an iOS device. I’ve got a modal which presents a login form for users and I want it to be fixed in place, no overscroll. Any suggestions on how to accomplish this?


#2

Hmm if overflow is disabled with this in your config.xml

<preference name="webviewbounce" value="false" />
<preference name="UIWebViewBounce" value="false" />
<preference name="DisallowOverscroll" value="true" />

Then I’m not sure what could be the issue. Can you post some code or a demo?


#3

I’ll see if I can come up with a pen, but I’ve not had it happen in a browser (Safari doesn’t do it), just on my iPhone, so putting it in a pen may be tricky. I do have config set with those three settings to disallow overscroll, yet I’m still seeing it happen on my modal window.


#4

Still having a problem with this, and still can’t figure it out.

In a modal window, it overscrolls even though I’ve got it disabled in config. Happens on both my iPhone 4s and my iPad.

Possibly unrelated, though it looks like overscroll here as well, in my ion-list, on these same devices I can overscroll upward and see the loading spinner after the list has loaded even though I don’t have pull-to-reload set up. Doesn’t happen in the browser or on Android.

Any suggestions for how I can test this? Since I can’t get it to happen in Safari, trying to figure out the cause has been tricky thus far.

Here’s what I had in my config, similar to what you showed:

<preference name="webviewbounce" value="false" />
<preference name="DisallowOverscroll" value="true" />
<preference name="UIWebViewBounce" value="false" />

#5

Hmm, it may not happen in safari, but I can make an app with a codepen, load it on a 4s and see if I can get it. Then I can create a repo on github and share the project.