Open Bug 1575877 Opened 6 years ago Updated 5 years ago

intl.regional_prefs.use_os_locales ignores custom date/time/number formats

Categories

(Core :: Internationalization, defect, P3)

68 Branch
defect

Tracking

()

UNCONFIRMED

People

(Reporter: bugzilla.mozilla.org, Unassigned)

Details

Attachments

(3 files)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Firefox/68.0

Steps to reproduce:

Install English Firefox on Windows.
Windows is setup in English with German locale and custom date format (yyyy-MM-dd)
Goto
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/date
and check CodePen or JSFiddle links

Actual results:

With intl.regional_prefs.use_os_locales = false, I get the US date format mm/dd/yyyy.
With intl.regional_prefs.use_os_locales = true, I get the DE date format dd.mm.yyyy.

Expected results:

intl.regional_prefs.use_os_locales = true shouldn't ignore custom date, time and number formats.

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → JavaScript: Internationalization API
Product: Firefox → Core

use_os_locales is part of the Internationalization component, therefore moving this bug over to that component.

Component: JavaScript: Internationalization API → Internationalization
Priority: -- → P3
Severity: normal → S3

I can reproduce this with 77.0.1 on Windows 10. In Windows Settings, set a short date format (I chose yyyy-mm-dd). Then in Firefox tick 'Use your operating system settings'. But an input control such as
<input type="date" value="2018-07-22">
still gets rendered as '07/22/2018' and not with the Windows configured date format 2018-07-22. I will attach three screenshots.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: