Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

ngLocale es-AR #8583

Closed
BartoGabriel opened this issue Aug 12, 2014 · 12 comments
Closed

ngLocale es-AR #8583

BartoGabriel opened this issue Aug 12, 2014 · 12 comments

Comments

@BartoGabriel
Copy link

I am Argentine. Our currency is not the Euro (https://github.com/angular/angular.js/blob/master/src/ngLocale/angular-locale_es-ar.js#L66)
Our currency symbol is "$". The symbol is placed before the number.

Example:
$ 14.212,82

@jeffbcross jeffbcross added this to the Backlog milestone Aug 13, 2014
@jeffbcross
Copy link
Contributor

Thanks for pointing it out, want to submit a PR?

@caitp
Copy link
Contributor

caitp commented Aug 13, 2014

We still get these from Closure Library, https://github.com/google/closure-library/blob/master/closure/goog/i18n/numberformatsymbolsext.js#L3938 (they are getting them from CLDR)

But, since we don't update the locales each release, a PR wouldn't hurt

BartoGabriel added a commit to BartoGabriel/angular.js that referenced this issue Aug 13, 2014
Currency symbol is '$'. The symbol is placed before the number.

Closes angular#8583
@lgalfaso
Copy link
Contributor

It looks like what is needed is also to include the extended number formats, this is

diff --git a/i18n/update-closure.sh b/i18n/update-closure.sh
index 4a9290d..576926c 100755
--- a/i18n/update-closure.sh
+++ b/i18n/update-closure.sh
@@ -14,4 +14,5 @@ curl "$I18N_BASE/currency.js" > closure/currencySymbols.js
 curl "$I18N_BASE/datetimesymbols.js" > closure/datetimeSymbols.js
 curl "$I18N_BASE/datetimesymbolsext.js" > closure/datetimeSymbolsExt.js
 curl "$I18N_BASE/numberformatsymbols.js" > closure/numberSymbols.js
+curl "$I18N_BASE/numberformatsymbolsext.js" >> closure/numberSymbols.js
 curl "$I18N_BASE/pluralrules.js" > closure/pluralRules.js

then update and generate the locales. I am not 100% happy with the change as this will also add ~100 new locales, but it is still better than having the wrong information in the locales we already ship

@caitp @jeffbcross WDYT?

@caitp
Copy link
Contributor

caitp commented Aug 20, 2014

there's wrong information in closure's numberSymbolsExt actually, so I'm not sure how that would really help. They don't supply the currency symbol for a lot of those latin countries, which is why we're getting issues about "argentina does not use the euro!" and stuff (because it just inherits from the default 'ES' locale).

Honestly we really just need to ditch closure and go with cldr directly, but I haven't been working on that for a few weeks, work is stale

mgallag pushed a commit to mgallag/angular.js that referenced this issue Sep 10, 2014
Fixes number formatting and symbols for many locales.
Adds support for additional locales.

Closes angular#8931
Closes angular#8583
Closees angular#7799
mgallag pushed a commit to mgallag/angular.js that referenced this issue Sep 10, 2014
Fixes number formatting and symbols for many locales.
Adds support for additional locales.

Closes angular#8931
Closes angular#8583
Closes angular#7799
mgallag added a commit to mgallag/angular.js that referenced this issue Sep 10, 2014
Fixes number formatting and symbols for many locales.
Adds support for additional locales.

Closes angular#8931
Closes angular#8583
Closes angular#7799
@caitp caitp closed this as completed in 6a96a82 Sep 11, 2014
@BartoGabriel
Copy link
Author

I do not think this completely resolved.

As I showed in the example, the correct way to display a value is:
$ 14.212,82
But now shown:
14.212,82 $

The error is in line 87,88,89,90:
https://github.com/angular/angular.js/blob/master/src/ngLocale/angular-locale_es-ar.js#L87

The correct way would be:

"negPre": "\u00a4-",
"negSuf": "",
"posPre": "\u00a4",
"posSuf": ""

@lgalfaso
Copy link
Contributor

@BartoGabriel it looks like that will be a lot harder. The issue is that the CLDR has two formats for currency for es-AR. These are
"accounting": "#,##0.00 ¤"
"standard": "¤#,##0.00"

For better or worst, the Closure Library is picking accounting (the other one is not even present). Then angular takes this from the Closure Library and generates the locales

@BartoGabriel
Copy link
Author

You are right, the error is drawn from CLDR.

I do not understand because reason is so in CLDR... We do not use the format that way.
But you have reason. The error should not be reported here, should be reported in CLDR, since the accounting format is wrong.

@srl295
Copy link

srl295 commented Sep 16, 2014

@BartoGabriel @caitp hi, CLDR person here. CLDR 26 has just finished final beta, please check latest CLDR data as well and provide feedback. Picking "accounting" by default sounds wrong off the top of my head. http://unicode.org/pipermail/unicode/2014-September/000935.html

@BartoGabriel
Copy link
Author

@srl295 hi, I already reported this in CLDR. But I received no response...
http://unicode.org/cldr/trac/ticket/7898

I also think the "standard" format must be used. But, I do not know that this decision will take.

@srl295
Copy link

srl295 commented Sep 16, 2014

@BartoGabriel Thanks for reporting it. CLDR meets weekly and so expect an update in about 24 hours. Is there a ticket raised against Closure?

@BartoGabriel
Copy link
Author

I did not report this to Closure.
Can be seen the pattern wrong:
https://github.com/google/closure-library/blob/master/closure/goog/i18n/numberformatsymbolsext.js#L3950

But these files are generated automatically. First should be arranged from the main source.
It seems important to know because "accounting format" is used by default.

@srl295
Copy link

srl295 commented Sep 17, 2014

@BartoGabriel @caitp see an update on the CLDR bug above. As to Closure, please file a bug with them, it turns out I have no contact with Closure.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants