Hacker News new | ask | show | jobs
by ArchReaper 2309 days ago
EDIT: removed my inaccurate comment, misread article
1 comments

How is the "tel" type a solution? According to the standard (https://html.spec.whatwg.org/multipage/input.html#telephone-...), it accepts every character except line feeds and carriage returns.

Without any pattern specified, the code you posted will accept emojis as input, it's not a good choice for a numeric only field. It's also intended for phone numbers...

Woops, for some reason I read the title as "Why the GOV.UK Design System team changed the input type for phone numbers" - removed my comment since it doesn't apply.