Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Numbers and units in measurement box are unlocalized #3597

Closed
1ec5 opened this issue Nov 19, 2016 · 3 comments · Fixed by #4672
Closed

Numbers and units in measurement box are unlocalized #3597

1ec5 opened this issue Nov 19, 2016 · 3 comments · Fixed by #4672
Assignees
Labels
localization Adapting iD across languages, regions, and cultures new contributor opportunity Best for first-time contributors without prior experience. You won’t be assigned; PRs welcome!

Comments

@1ec5
Copy link
Collaborator

1ec5 commented Nov 19, 2016

The measurement box has unlocalized numbers and units. Here it is in Vietnamese; the decimal separator should be a comma but it’s a period instead. Similarly, the unit abbreviations can’t be localized.

inspector

@bhousel bhousel added the localization Adapting iD across languages, regions, and cultures label Nov 19, 2016
@kepta
Copy link
Collaborator

kepta commented Jan 11, 2017

We could take a look at this library for internationalisation

@1ec5
Copy link
Collaborator Author

1ec5 commented Oct 5, 2017

We could take a look at this library for internationalisation

The i18n package appears to handle pluralization but not number or unit localization. Globalize.js is a popular package for a number of localization tasks, including formatting numbers and numbers with units. It uses a slice of data from CLDR, so it isn’t necessary for iD’s localizers to specify the number and unit formats.

@1ec5
Copy link
Collaborator Author

1ec5 commented Dec 6, 2017

Actually, Number.toLocaleString() should be sufficient for localizing these values in modern browsers.

@1ec5 1ec5 added the new contributor opportunity Best for first-time contributors without prior experience. You won’t be assigned; PRs welcome! label Dec 6, 2017
@1ec5 1ec5 self-assigned this Jan 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
localization Adapting iD across languages, regions, and cultures new contributor opportunity Best for first-time contributors without prior experience. You won’t be assigned; PRs welcome!
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants