2
I have a page with a numeric input with autofocus:
<input type="number" placeholder="Informe" ng-model='leitura.leituraatual' required="true" autofocus="true">
The problem is that the keyboard appears in Text mode instead of numerical mode. Only the number pad appears if I click the input manually.
I did so:
$scope.$on('$ionicView.enter', function(){ $window.document.getElementById("txtLeituraAtual").focus(); });
. Now the input even gets the focus but the keyboard does not open.– NilsonUehara
Add
cordova.plugins.Keyboard.show();
after thefocus()
keyboard opens, but in text mode. I wanted it to open in numeric mode.– NilsonUehara
Try to change the
type
from the input totel
, to test.– Rafael Telles