Currently I have the following block attached to the user action.
$(".class-botao").focus()
When the user interacts with the page the mobile keyboard is displayed normally.
But in my application there is a method that checks if there is any empty input when loading the page and if there is I give .focus()
in the element;
autoFocus: function(scope) {
var firstInput = $('.class-input.empty:required').filter(':first:visible');
if (!firstInput.length) {
return false;
}
firstInput.focus();
return true;
},
Everything works normally but the keyboard does not appear (IOS / Android),
I have tried to simulate events .trigger('click // touchstart')
shortly after focus()
, but nothing on the keyboard appears: /
Does anyone have any tips?