Bug 247242 - Locale inconsistency in inputmode="decimal" and input type="number"
Summary: Locale inconsistency in inputmode="decimal" and input type="number"
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Forms (show other bugs)
Version: Safari 16
Hardware: iPhone / iPad iOS 16
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-10-30 07:42 PDT by Rene
Modified: 2022-11-06 06:43 PST (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rene 2022-10-30 07:42:21 PDT
iPhone decimal keyboard does not always match with the decimal separator used in number input.

Steps to repro:
- have <input type="number" inputmode="decimal" value="1.99">
- have iPhone region set to location that uses comma as decimal separator (for example Estonia)
- have iPhone number format set to 1,234,567.89
- open the page in Safari. Safari displays the input as "1,99".
- try to edit the field -- Decimal keyboard has "." instead of ",".

The best expected result:
- input should honor the locale defined by <html lang> and display the input values and keyboard accordingly. So in case on <html lang="en-US> the input displays "1.99" and keyboard has "." and in case of <html lang="et">, the input displays "1,99" and keyboard has ",".

Minimum expected result:
- Both input and keyboard match with eatch other (preferably using the number format chosen in iPhone settings).
Comment 1 Radar WebKit Bug Importer 2022-11-06 06:43:17 PST
<rdar://problem/102011933>