design-web-toolkit icon indicating copy to clipboard operation
design-web-toolkit copied to clipboard

Datepicker - error during validation W3C.

Open dipartimentotrasformazionedigitale opened this issue 7 years ago • 1 comments

Using the url: https://validator.w3.org and checking the datepicker link: https://italia.github.io/design-web-toolkit/components/preview/datepicker.html, it shows 3 errors on Attribute pattern.

Please could you help us to find solution?

Thanks.

as u wrote attribute pattern is not valid for input of type number.

my own idea is this, to use type number or similar is not a full-compatible cross-browsing solution, the benefit you have with built-in validation is not enough, you could use js validation and also server side validation (always remember) to be free to validate what ever you want and with different feedback layout.

anyway, just to validate w3c, you have to use type "text" of the input, you could insert text instead only numbers, but when you submit the form it validates according to the pattern.

mbolzan avatar Sep 28 '18 08:09 mbolzan