ionic-team / cordova-plugin-ionic-keyboard

Keyboard Plugin for Cordova
Other
193 stars 178 forks source link

Keyboard does not resize content when StatusBar is hidden. #61

Closed RobusXLR closed 5 years ago

RobusXLR commented 5 years ago

Bug Report

Ionic version: 4.0.0-rc0

Current behavior: If StatusBar is hidden then the application content will not resize when the keyboard is shown. This leads to input elements being covered by the keyboard.

This issue affects Android. Not tested on iOS or Windows.

Expected behavior: Application area to resize to account for keyboard.

Steps to reproduce:

  1. Create a new blank project.

    ionic start test blank --type=angular
  2. Fill home page content with inputs.

    
    <ion-header>
    <ion-toolbar>
        <ion-title>
            Ionic Blank
        </ion-title>
    </ion-toolbar>
    </ion-header>
Input 1 Input 2 Input 3 Input 4 Input 5 Input 6 Input 7 Input 8

3. In AppComponent, hide the StatusBar

export class AppComponent {

constructor(
    private platform: Platform,
    private splashScreen: SplashScreen,
    private statusBar: StatusBar,
) {
    this.initializeApp();
}

initializeApp() {
    this.platform.ready().then(() => {
        this.statusBar.styleDefault();
        this.statusBar.hide();            // This line causes the problem.
        this.splashScreen.hide();
    });
}

}

4. Run on Android device. Click on an ion-input. Keyboard will cover some inputs. Inputs cannot be scrolled into view.

**Ionic info:** 

Ionic:

ionic (Ionic CLI) : 4.5.0 (C:\Users\Robert.gill\AppData\Roaming\npm\node_modules\ionic) Ionic Framework : @ionic/angular 4.0.0-rc.0 @angular-devkit/build-angular : 0.11.4 @angular-devkit/schematics : 7.1.4 @angular/cli : 7.1.4 @ionic/angular-toolkit : 1.2.2

Cordova:

cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1) Cordova Platforms : android 7.1.4 Cordova Plugins : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 2.3.1, (and 8 other plugins)

System:

Android SDK Tools : 26.1.1 (C:\Users\Robert.gill\AppData\Local\Android\Sdk) NodeJS : v8.11.3 (C:\Program Files\nodejs\node.exe) npm : 6.1.0 OS : Windows 10

ffMathy commented 5 years ago

Same for Ionic 4 RC2.

Lehren commented 5 years ago

Also happens with overlaysWebView(true)

amitairos commented 5 years ago

Any updates on this?

Fayozjon commented 5 years ago

CONFIRMED! Ionic 3 also has this issue

konnectappdev commented 5 years ago

+1

sergip76 commented 5 years ago

I have the same problem. Please, we need an update to solve it.

NisStrom commented 5 years ago

+1

mcornillon87 commented 5 years ago

+1

lorddrak commented 5 years ago

+1

lorddrak commented 5 years ago

on config.xml adding <preference name="KeyboardResize" value="true" /> fixes this problem

ffMathy commented 5 years ago

Yes @lorddrak but the root issue should still be fixed.

PierratSamuel commented 5 years ago

+1

vlafranca commented 5 years ago

on config.xml adding <preference name="KeyboardResize" value="true" /> fixes this problem

not working for me ... any other workaround ?

MASP3000 commented 5 years ago

same problem here....

matheenbenfy commented 5 years ago

Same problem here too.

prescindivel commented 5 years ago

same problem

Juanperezc commented 5 years ago

same problem