I’m creating an app with a chat room for iOS and when I send a new message it blurs the input field and the keyboard slides down. I already tried all solutions from following article, but not work.
I’m creating an app with a chat room and when I submit a new message it blurs the input field and the keyboard slides down. What would be a good way to keep the focus on the field and keep the keyboard up?
I started out with the autofocus html tag and that makes the input field start autofocused in the browser but not in the emulator or device. Then I tried ng-focus="true" and ng-focus="contentFocus" and set it true before and as a callback to the POST call and still no dice.
Is there any solution to make it work properly? Thanks
1 Like
It does not yet seem possible to implement a simple chat page in Ionic2 where the keyboard stays up in between messages.
Im surprised as the chat functionality is a basic thing used by many apps.
2 Likes
Did you manage to find a solution for this? I’m also creating a chat app and struggling with this.
1 Like
use this simple combination;
<ion-button (mousedown)="$event.preventDefault(); sendTheMessage()">