Edge HTML <input type="number"> still accept alphabet characters

Issue #17313919 • Assigned to Bogdan B.


Grisha L.
Apr 30, 2018
This issue is public.
Found in
  • Microsoft Edge
Found in build #
Reported by 2 people

Sign in to watch or report this issue.

Steps to reproduce

Edge doesn’t follow the spec - https://html.spec.whatwg.org/multipage/input.html#number-state-(type%3Dnumber)

Nor it is interoperable with Chrome


0 attachments

    Comments and activity

    • Microsoft Edge Team

      Changed Assigned To to “Steven K.”

      Changed Assigned To to “Mohamed S.”

      Changed Assigned To to “Bogdan B.”

    • Originally reported at https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/10538279/, it appears this is either a regression or it was never actually fixed.

      `` will let you enter abc. You will get a validation error on form submit, but the expected behavior is that the input box will not let you input the letters in the first place.

      This is important because if you are using the value elsewhere in the page, you can’t use HTML5 validation to ensure that the input box only contains expected values, you must resort to JavaScript validation.

    • This issue appears to be related to small step sizes and numbers near the min. Using step="0.01" min="1.0" and 1.2 will validate but anything between 1 and 1.19 will not validate. If I change min="2" it will not validate with 2.01.

      Note: Problem goes away if min="0".

    • Oops, above comment is for another bug with input type="number". Please delete.

    You need to sign in to your Microsoft account to add a comment.

    Sign in