institut-de-genomique / Ultimate-DataTable

This AngularJS directive generate a HTML table with build-in fonctionnality like save, edit, remove, pagination etc...
http://institut-de-genomique.github.io/Ultimate-DataTable/
45 stars 26 forks source link

I18n fix #15

Closed ydeshayes closed 8 years ago

ydeshayes commented 8 years ago

Hello !

https://github.com/institut-de-genomique/Ultimate-DataTable/issues/14

I add a new init function in the I18n service that select the language. We can now give a String or an array of String to the I18n service constructor in order to use the navigator.languages new generation browser function.

The init function try to find a translation with the all string (xx-XX) and if there is no translation for the extended language, we try with the primary language only (xx). The default language is 'en'.

The Messages function is now pure, because the check of the language is only on the init function.

Some additionnal informations.

Jenselme commented 8 years ago

LGTM. Can you merge this?

Jenselme commented 8 years ago

Thanks.