Implement Intl.NumberFormat Unified API proposal
Categories
(Core :: JavaScript: Internationalization API, enhancement)
Tracking
()
Tracking | Status | |
---|---|---|
firefox70 | --- | fixed |
People
(Reporter: anba, Assigned: anba)
References
(Blocks 2 open bugs)
Details
(Keywords: dev-doc-complete)
Attachments
(11 files)
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details | |
(deleted),
text/x-phabricator-request
|
Details |
Implement the "Intl.NumberFormat Unified API proposal" from https://github.com/tc39/proposal-unified-intl-numberformat.
Updated•5 years ago
|
Assignee | ||
Comment 2•5 years ago
|
||
Implements the changes to SetNumberFormatDigitOptions
and FormatNumberToString
,
except for the support of the new "compact-rounding" mode.
Assignee | ||
Comment 3•5 years ago
|
||
Depends on D38328
Assignee | ||
Comment 4•5 years ago
|
||
Depends on D38329
Assignee | ||
Comment 5•5 years ago
|
||
Depends on D38330
Assignee | ||
Comment 6•5 years ago
|
||
Depends on D38331
Assignee | ||
Comment 7•5 years ago
|
||
Depends on D38332
Assignee | ||
Comment 8•5 years ago
|
||
Depends on D38334
Assignee | ||
Comment 9•5 years ago
|
||
Also splits NumberFormatterSkeleton::currencyDisplay
from NFS::currency
for
consistency with the other new methods added as part of this bug.
Depends on D38335
Assignee | ||
Comment 10•5 years ago
|
||
This gives a nicer error when a sanctioned unit identifier isn't supported by
the current ICU.
Depends on D38336
Assignee | ||
Comment 11•5 years ago
|
||
Some parts of the proposal haven't yet stabilised enough to consider it safe to
let them ride the trains, so for now they're restricted to nightly-only:
- currencyDisplay
- Latest decision was to rename "narrow-symbol" to "narrowSymbol".
- currencySign
- Seems to have no open issues, so maybe okay to ship.
- unit and unitDisplay
- List of supported units is still changing.
- notation and compactDisplay
- There's an open issue at the proposal repository to change "compact" notation
to match ICU's behaviour.
- signDisplay
- Latest decision was to rename "except-zero" to "exceptZero".
- "except-zero" implementation in ICU doesn't seem to match spec, see test cases.
- minimumIntegerDigits with fraction digits
- This particular change seems safe to ship and won't be restricted to nightly-only.
Depends on D38337
Assignee | ||
Comment 12•5 years ago
|
||
Depends on D38338
Assignee | ||
Comment 13•5 years ago
|
||
Try: https://treeherder.mozilla.org/#/jobs?repo=try&revision=7e0e2572dcbb8013761e10d33b59b46d80f28a8d
Comment 14•5 years ago
|
||
Pushed by archaeopteryx@coole-files.de:
https://hg.mozilla.org/integration/autoland/rev/f7bdf614286f
Part 1: Apply "minimumIntegerDigits" to number-formatters with fraction-digits. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/092c670c39d8
Part 2: Change variable names in InitializeNumberFormat to match current spec. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/a4956d9ba377
Part 3: Add support for "signDisplay" option. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/72e2ae2d6b44
Part 4: Add support for "notation" and "compactDisplay" options. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/0cfc8d6f068b
Part 5: Add support for "currencySign" option. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/cf75de6c4bcf
Part 6: Add units to ICU data file. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/eac1f92a3634
Part 7: Add support for "unit"-style and "unitDisplay" options. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/4089aeb62e58
Part 8: Add support for "narrow-symbol" currency-display style. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/66f565be1e49
Part 9: Handle the case when a system ICU supports a different set of measurement units. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/d9c693ce8443
Part 10: Restrict proposal changes to nightly-only. r=jwalden
https://hg.mozilla.org/integration/autoland/rev/3cc69158d573
Part 11: Enable test262 tests. r=jwalden
Comment 15•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/f7bdf614286f
https://hg.mozilla.org/mozilla-central/rev/092c670c39d8
https://hg.mozilla.org/mozilla-central/rev/a4956d9ba377
https://hg.mozilla.org/mozilla-central/rev/72e2ae2d6b44
https://hg.mozilla.org/mozilla-central/rev/0cfc8d6f068b
https://hg.mozilla.org/mozilla-central/rev/cf75de6c4bcf
https://hg.mozilla.org/mozilla-central/rev/eac1f92a3634
https://hg.mozilla.org/mozilla-central/rev/4089aeb62e58
https://hg.mozilla.org/mozilla-central/rev/66f565be1e49
https://hg.mozilla.org/mozilla-central/rev/d9c693ce8443
https://hg.mozilla.org/mozilla-central/rev/3cc69158d573
Comment 16•4 years ago
|
||
For docs, see https://bugzilla.mozilla.org/show_bug.cgi?id=1633836#c8
Description
•