Closed
Bug 1073307
Opened 10 years ago
Closed 8 years ago
Date.prototype.toLocaleTimeString doesn't support IANA timezone names
Categories
(Core :: JavaScript: Internationalization API, defect)
Tracking
()
RESOLVED
FIXED
mozilla52
Tracking | Status | |
---|---|---|
firefox52 | --- | fixed |
People
(Reporter: nicolas, Assigned: anba)
References
Details
(Keywords: dev-doc-complete)
Attachments
(1 file, 1 obsolete file)
8.51 KB,
patch
|
anba
:
review+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1700.6 Safari/537.36
Steps to reproduce:
Call `Date().toLocaleTimeString('fr', { timeZone: 'Europe/Paris' })` in JavaScript.
Actual results:
The timezone that was used is GMT.
Expected results:
The time should be converted to the specified timezone.
This was sent from Chromium since I'm currently rebuilding Firefox ;)
While the spec (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleTimeString) states handling IANA timezone names isn't mandatory, it is extremely convenient and JavaScript applications might rely on it.
The rationale is similar to https://bugzilla.mozilla.org/show_bug.cgi?id=837961
Assignee | ||
Updated•9 years ago
|
Component: JavaScript Engine → JavaScript: Internationalization API
Comment 2•9 years ago
|
||
Yeah, it's something we should do. Not certain when, but it'll happen eventually.
(I kinda feel like this is a dup, but if André didn't tag it so I'm not going to pretend second-guess him. :-) )
Status: UNCONFIRMED → NEW
Ever confirmed: true
Assignee | ||
Comment 3•8 years ago
|
||
No additional code changes, except for the ones in bug 837961, are required to support the timeZone property for Date.prototype.toLocale{Date,Time}String(). We only need to test everything works as expected.
Assignee: nobody → andrebargull
Status: NEW → ASSIGNED
Attachment #8786843 -
Flags: review?(jwalden+bmo)
Updated•8 years ago
|
Keywords: dev-doc-needed
Updated•8 years ago
|
Attachment #8786843 -
Flags: review?(jwalden+bmo) → review+
Assignee | ||
Comment 4•8 years ago
|
||
Updated patch to include comments requested for similar tests in bug 837961. Carrying r+ from Waldo.
Attachment #8786843 -
Attachment is obsolete: true
Attachment #8806364 -
Flags: review+
Assignee | ||
Updated•8 years ago
|
Keywords: checkin-needed
Pushed by cbook@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/551718400ad4
Add tests for timeZone support in Date.prototype.toLocaleString. r=Waldo
Keywords: checkin-needed
Comment 6•8 years ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox52:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla52
Comment 7•8 years ago
|
||
See bug 837961 comment 70 for doc updates.
Keywords: dev-doc-needed → dev-doc-complete
You need to log in
before you can comment on or make changes to this bug.
Description
•