Bug with keyboard shrink

When using Keyboard shrink, the screen goes behind the statusbar:

If this is a Cordova project, have you installed cordova-plugin-keyboard?

1 Like

yes i am using cordova plugin keyboard

it happens only when keyboard activated

What version are you using in your app?

cordova-plugin-keyboard npm * 1.2.0

using phonegap build, which picks automatic the latest version

so no idea how to fix that?

You need to call Keyboard.shrinkView(true); on deviceready

thats what i do

but i still get that bug

1 Like

Please, try it in index.js

document.addEventListener("deviceready", onDeviceReady, false);

function onDeviceReady() {

    Keyboard.shrinkView(true);

}

I dont have a index.js,

i have just one logic.js which is loaded at index.html

and this is the code it contians:

// Handle Cordova Device Ready Event
$$(document).on('deviceready', function() {
	deviceready = true;
	StatusBar.styleDefault();
	
	Keyboard.shrinkView(true);
	Keyboard.disableScrollingInShrinkView(true);
	Keyboard.hideFormAccessoryBar(true);

should i maybe call the Keyboard.shrinkView(true) much earlier? or what could caus this bug??

2 Likes

so no idea on how to fix this??

It apears also that on android, my message bar stays behinde the keyboard.

Manged to fix it:
this is my Solution:

in config.xml:

<preference name="DisallowOverscroll" value="true" />
<preference name="orientation" value="portrait" />
<preference name="Fullscreen" value="true" />
<preference name="HideKeyboardFromAccessoryBar" value="true" />
<plugin name="cordova-plugin-statusbar" />

in index.html:

	<div id="app" class="">
		<div class="statusbar"></div>

in index.js:

app = new Framework7({
	....
	statusbar: {
		enabled: true,
		overlay: true,
	},
	....

that worked for me

1 Like

hello i have the same problem and - tried also your settings but still not work. do you have a solution?