RESOLVED DUPLICATE of bug 197916 200226
Wrong keyboard for "inputmode=numeric"
https://bugs.webkit.org/show_bug.cgi?id=200226
Summary Wrong keyboard for "inputmode=numeric"
Brad
Reported 2019-07-29 08:39:28 PDT
The "numeric" and "decimal" values of `inputmode` are both supposed to trigger number keyboards, with "decimal" being different only in that it should include the decimal point. Both should be able to enter any whole number, while "decimal" should also be able to enter decimal numbers, via the addition of a decimal point key on the keyboard. But in iOS Safari, "numeric" creates a keyboard with more keys instead of fewer. It can type decimals because it also includes a decimal point (period) key. But it strangely can also type all sorts of punctuation. So as an author, if I have a field that I want people to only type whole numbers into, I want to be able to specify "inputmode=numeric" and get a keyboard that has numbers, minus sign, and nothing else, in order to discourage expectations that other keys are acceptable. But in iOS Safari, I get something else completely. This bug then leads me to use "inputmode=decimal" when I don't really want decimal, because at least it is a number keypad and doesn't actually have a bunch of irrelevant punctuation keys (this is assuming I don't care about the negative key missing from decimal, which is another bug). So, what I'm saying is that this bug is harming the Web by causing authors to put the wrong thing into their HTML. And it is likely to harm iOS worse than Android, because authors will detect the platform and include "decimal" for iOS and "numeric" for Android, in order to get the closest result to what they really want.
Attachments
Wenson Hsieh
Comment 1 2019-07-29 08:42:58 PDT
After r245338, inputmode=“numeric” should now show the numeric keyboard (i.e. a 0-9 keypad). This change should be in the latest iOS 13 beta — could you verify that it’s fixed there?
Alexey Proskuryakov
Comment 2 2019-07-30 09:12:17 PDT
Marking as a duplicate based on Wenson's comment. Please feel free to re-open if this is still an issue. *** This bug has been marked as a duplicate of bug 197916 ***
Note You need to log in before you can comment on or make changes to this bug.