ecma402 icon indicating copy to clipboard operation
ecma402 copied to clipboard

Add binary prefix units

Open sffc opened this issue 5 years ago • 6 comments

Binary units such as KiB and MiB reduce ambiguity associated with kB and MB. We have received numerous requests to add them to ECMA-402. This is currently blocked by upstream CLDR not having locale data for these units.

Upstream ticket:

https://unicode-org.atlassian.net/browse/CLDR-13848

Relevant CLDR discussions:

  • https://unicode-org.atlassian.net/browse/CLDR-7214
  • https://unicode-org.atlassian.net/browse/CLDR-11454

User requests:

  • https://github.com/tc39/ecma402/issues/32#issuecomment-468145082
  • https://goo.gle/devtools-si

@mathiasbynens @markusicu @macchiati

sffc avatar Jun 02 '20 03:06 sffc

If we are just adding the prefixes, then the work could be feasible. However, it is very late in the cycle for us to be adding new data for translation, so I will add this to the CLDR agenda tomorrow.

I think it would be bounded to the following (this is the English version): 16 strings per language. Does this look right, Shane?

long

kibi{0} mebi{0} gibi{0} tebi{0} pebi{0} exbi{0} zebi{0} yobe{0}

short

KiB{0} MiB{0} GiB{0} TiB{0} PiB{0} EiB{0} ZiB{0} YiB{0}

Mark

On Mon, Jun 1, 2020 at 8:32 PM Shane F. Carr [email protected] wrote:

Binary units such as KiB and MiB reduce ambiguity associated with kB and MB. We have received numerous requests to add them to ECMA-402. This is currently blocked by upstream CLDR not having locale data for these units.

Relevant CLDR discussions:

  • https://unicode-org.atlassian.net/browse/CLDR-7214
  • https://unicode-org.atlassian.net/browse/CLDR-11454

User requests:

@mathiasbynens https://github.com/mathiasbynens @markusicu https://github.com/markusicu @macchiati https://github.com/macchiati

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tc39/ecma402/issues/449, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACJLEMFCL7F432OIJ6W57QDRURXDVANCNFSM4NQK42IQ .

macchiati avatar Jun 02 '20 21:06 macchiati

I created a ticket for discussion. Please add comments there: https://unicode-org.atlassian.net/browse/CLDR-13848

Mark

On Tue, Jun 2, 2020 at 2:35 PM Mark Davis ☕️ [email protected] wrote:

If we are just adding the prefixes, then the work could be feasible. However, it is very late in the cycle for us to be adding new data for translation, so I will add this to the CLDR agenda tomorrow.

I think it would be bounded to the following (this is the English version): 16 strings per language. Does this look right, Shane?

long

kibi{0} mebi{0} gibi{0} tebi{0} pebi{0} exbi{0} zebi{0} yobe{0}

short

KiB{0} MiB{0} GiB{0} TiB{0} PiB{0} EiB{0} ZiB{0} YiB{0}

Mark

On Mon, Jun 1, 2020 at 8:32 PM Shane F. Carr [email protected] wrote:

Binary units such as KiB and MiB reduce ambiguity associated with kB and MB. We have received numerous requests to add them to ECMA-402. This is currently blocked by upstream CLDR not having locale data for these units.

Relevant CLDR discussions:

  • https://unicode-org.atlassian.net/browse/CLDR-7214
  • https://unicode-org.atlassian.net/browse/CLDR-11454

User requests:

@mathiasbynens https://github.com/mathiasbynens @markusicu https://github.com/markusicu @macchiati https://github.com/macchiati

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tc39/ecma402/issues/449, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACJLEMFCL7F432OIJ6W57QDRURXDVANCNFSM4NQK42IQ .

macchiati avatar Jun 02 '20 21:06 macchiati

Note that I fixed the typos in the ticket to drop the B from the short forms.

Mark

On Tue, Jun 2, 2020 at 2:45 PM Mark Davis ☕️ [email protected] wrote:

I created a ticket for discussion. Please add comments there: https://unicode-org.atlassian.net/browse/CLDR-13848

Mark

On Tue, Jun 2, 2020 at 2:35 PM Mark Davis ☕️ [email protected] wrote:

If we are just adding the prefixes, then the work could be feasible. However, it is very late in the cycle for us to be adding new data for translation, so I will add this to the CLDR agenda tomorrow.

I think it would be bounded to the following (this is the English version): 16 strings per language. Does this look right, Shane?

long

kibi{0} mebi{0} gibi{0} tebi{0} pebi{0} exbi{0} zebi{0} yobe{0}

short

KiB{0} MiB{0} GiB{0} TiB{0} PiB{0} EiB{0} ZiB{0} YiB{0}

Mark

On Mon, Jun 1, 2020 at 8:32 PM Shane F. Carr [email protected] wrote:

Binary units such as KiB and MiB reduce ambiguity associated with kB and MB. We have received numerous requests to add them to ECMA-402. This is currently blocked by upstream CLDR not having locale data for these units.

Relevant CLDR discussions:

  • https://unicode-org.atlassian.net/browse/CLDR-7214
  • https://unicode-org.atlassian.net/browse/CLDR-11454

User requests:

@mathiasbynens https://github.com/mathiasbynens @markusicu https://github.com/markusicu @macchiati https://github.com/macchiati

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tc39/ecma402/issues/449, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACJLEMFCL7F432OIJ6W57QDRURXDVANCNFSM4NQK42IQ .

macchiati avatar Jun 02 '20 21:06 macchiati

<unitPrefixPattern>yobe{0}</unitPrefixPattern>

should be yobi

ByteEater-pl avatar Jun 19 '20 15:06 ByteEater-pl

Thanks. I added https://unicode-org.atlassian.net/browse/CLDR-13848?focusedCommentId=156911

Mark

On Fri, Jun 19, 2020 at 8:53 AM Krzysztof Maczyński < [email protected]> wrote:

yobe{0}

should be yobi

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tc39/ecma402/issues/449#issuecomment-646709093, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACJLEMA2IL2LZOKQSAFCBBTRXOCW5ANCNFSM4NQK42IQ .

macchiati avatar Jun 19 '20 20:06 macchiati

CLDR now contains strings for the binary prefixes:

https://github.com/unicode-org/cldr/blob/main/common/main/en.xml#L6128

https://github.com/unicode-org/cldr/blob/main/common/main/ar.xml#L10572

I had expected to see shorthand units like "KiB":

image

source: https://en.wikipedia.org/wiki/Kilobyte

But it seems kibibyte and friends only have a "long" string specified.

But perhaps that'd need to be a digital-kibibyte unit in CLDR?

connorjclark avatar Apr 06 '22 22:04 connorjclark