0
votes

I am running it on the browser, emulator, real device it works perfectly but then I tried to run it on Android version 9 it didn't work.

Can't tap to edit on ion-input on Android 9.

I want to tap the edit input, so I can enter my username or password.

After making a manual action like tapping a button to log in, only then I'm able to tap the edit input to enter my username or password.

When I install it on a real device with OS Android 9, I try to tap the username or password input but It didn't work until I tap another component like a button to log in.

version Information

Ionic:

ionic (Ionic CLI) : 4.12.0 (C:\Users\Varni 2\AppData\Roaming\npm\node_modules\ionic)
Ionic Framework : ionic-angular 3.9.9
@ionic/app-scripts : 3.2.4

Cordova:

cordova (Cordova CLI) : 9.0.0 ([email protected])
Cordova Platforms : android 8.1.0
Cordova Plugins : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 4.1.3, (and 4 other plugins)

System:

Android SDK Tools : 26.1.1 (C:\Android\Sdk)
NodeJS : v12.13.1 (C:\Program Files\nodejs\node.exe)
npm : 6.12.1
OS : Windows 10

login.html

<ion-content padding id="login">
  <ion-grid>
    <ion-row>
      <ion-col text-center>
        <img src="../../assets/imgs/logo.png" class="logo" />
      </ion-col>
    </ion-row>
    <ion-row>
      <ion-col text-center>
        Welcome to Sugaj Sindhi Samiti
      </ion-col>
    </ion-row>
  </ion-grid>

  <div>
    <form (ngSubmit)="login()">
      <ion-row>
        <ion-col>
          <ion-list >
            <ion-item>
              <ion-input placeholder="Contact No" type="number" name="contact_no" [(ngModel)]="userData.contact_no"></ion-input>
            </ion-item>

            <ion-item>
              <ion-input placeholder="Password" type="password" name="password" [(ngModel)]="userData.password"></ion-input>
            </ion-item>
          </ion-list>
        </ion-col>
      </ion-row>

      <button class="marginTop buttonLogin" ion-button full color="primary" type="submit">Log in</button>
    </form>
  </div>

  <button class="marginT buttonLogin" ion-button full color="primary" (click)="register()">Register</button>
  <ion-row class="marginT">
    <ion-col text-center>
      <a href="#" (click)="forgotPassword()">Forgot Password?</a>
    </ion-col>
  </ion-row>
</ion-content>      

enter image description here

1

1 Answers

0
votes

On your app.module.ts put this code inside imports tag:

IonicModule.forRoot(MyApp, {
    platforms: {
        android: {
            activator: 'none'
        }
    },
    scrollAssist: false, autoFocusAssist: false
})