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

Incorrect Currency & Number Format for es-us Locale #8931

Closed
@mgallag

Description

@mgallag

The en-us locale configuration incorrectly uses a comma for number formatting, € as a default currency symbol, places the currency symbol after the amount and uses a decimal as the group separator. Number and currency rules should be similar to en-us locale rules.

<!doctype html>
<html lang="es">
<head>
  <meta charset="UTF-8">
  <title>Incorrect Number and Currency Format: es-us</title>
  <script src="//code.angularjs.org/1.2.23/angular.js"></script>
  <script src="//code.angularjs.org/1.2.23/i18n/angular-locale_es-us.js"></script>
</head>
<body ng-app="myApp"> 
  <script>
    angular.module('myApp', ['ngLocale'])
      .controller('MyCtrl', ['$scope', '$locale', function($scope, $locale) {
        $scope.localeId = $locale.id;
        $scope.amount = 1234.56;
      }]);
  </script>
  <ul ng-controller="MyCtrl">
    <li>{{localeId}}</li>
    <li>{{amount | currency}}</li>
    <li>{{amount | number : 2}}</li>
  </ul>
</body>
</html>

Expected:

  • es-us
  • $1,234.56
  • 1,234.56

Actual:

  • es-us
  • 1.234,56 €
  • 1.234,56

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions