I have a simple view with a login form. On Android, if the keyboard is opened, the content is not scrolling up to prevent it from getting behind the keyboard.
I followed the Keyboard instructions from the docs, and read a lot of forum posts, but I haven't figured it out.
I installed the Keyboard plugin com.ionic.keyboard
.
This is the structure of the page:
<ion-nav-view>
<ion-view>
<ion-content>
...<form>..Login form..</form>...
</ion-content>
</ion-view>
</ion-nav-view>
If I put some extra dummy content in the page, it shows that ion-content is indeed scrollable. However, it's not moving up when the keyboard is opened by focusing on an input.
- Ionic version?
1.0.0-beta.13
- Is my app fullscreen? No
- Did I test if the keyboard plugin is working? Yes
Is there anything else I have to do?
I have prevent this scrolling property in my project by setting below values in AndroidManifest.xml file.
android:windowSoftInputMode = "adjustNothing"
Please check whether
android:windowSoftInputMode
value isadjustResize
or not in AndroidManifest.xml. If not please update it toadjustResize
.I hope this will you. Thanks
description from documentation here
In my case there is a footer that hides the input when the keyboard is showing.
Seeing github.com/driftyco/ionic/issues/2151, although its a closed bug it seems that its still an issue.
To me it seems that the scrolling doesn't know how to calculate properly whether it should scroll or not, because it doesn't take under account the footer in its calculations. If the content is big enough from the first place then it knows it has to scroll anyway.
I've ended up using
and adding some
<br/>
at the bottom of myion-content
. There is enough space so it won't effect anything for me, bug will cause the scroll to work properly.In the section where you declare the keyboard plugin, try to add this: