Hi,
I managed to get a nice log in form with the following code:
<form #loginForm="ngForm" novalidate id="loginForm" padding> <ion-list no-lines> <ion-item class="inputField"> <ion-label stacked>Email</ion-label> <ion-input [(ngModel)]="login.username" name="username" type="text" #username="ngModel" spellcheck="false" autocapitalize="off"> </ion-input> </ion-item> <ion-item class="inputField"> <ion-label stacked>Password</ion-label> <ion-input [(ngModel)]="login.password" name="password" type="password" #password="ngModel"> </ion-input> </ion-item> </ion-list> <ion-row responsive-sm> <ion-col> <button ion-button (click)="onLogin(loginForm)" type="submit" block class="loginButton">LOG IN</button> </ion-col> </ion-row> </form>
It looks quite nice and the onLogin function is well implemented.
Unfortunately, I had bad user experience with this form.
For each field, the keyboard shows the âSubmitâ button.
Typically, when I first enter username, if I enter âSubmitâ button, the form is submitted without the password field.
Is there a way to show a keyboard without the âSubmitâ button so the keyboard will just dismiss if user hits the âEnter buttonâ without needing to click anywhere else in the screen? In this case, the form will be submitted only if user hits the âLOG INâ button in the form.