freedomotic / fd-vue-webapp

A Vue.js web application for Freedomotic Open IoT framework
http://fd-vue-webapp.herokuapp.com/
GNU Affero General Public License v3.0
65 stars 66 forks source link

Add auto detection of Language #178

Open Remeic opened 6 years ago

Remeic commented 6 years ago

Issue related to #9

Add auto detection of language using navigator.language, i create an object with key and value. Keys are the values can be returned by navigator.languages ( list here ) and values are our label for i18n translation files.

Navigator language is set to lowercase for support also safari < 10.2 (here)

I wanted to add test too, but test suite pass every time, even if i try to write test that fail.

I hope my contribution can be useful

amenak77 commented 6 years ago

@Remeic we will do some old style tests ASAP. ;) thank you very much for your contribution; feel free to choose another issue if you want to. Bye, Alberto