[locale] add catalan

https://framagit.org/les/gancio/merge_requests/2
This commit is contained in:
les 2019-12-18 14:59:10 +01:00
parent d9be784500
commit 4a5e5617ee
3 changed files with 6 additions and 2 deletions

View file

@ -1,5 +1,9 @@
All notable changes to this project will be documented in this file.
### unreleased
[locale] add catalan
[fix] fedi outbox
### 0.17.12
- [ui] add admin section on event page in mobile #63
- [fix] remove username from users

View file

@ -9,7 +9,7 @@ import locale from 'element-ui/lib/locale'
const locales = {
it: require('element-ui/lib/locale/lang/it'),
en: require('element-ui/lib/locale/lang/en'),
es: require('element-ui/lib/locale/lang/es')
es: require('element-ui/lib/locale/lang/es'),
ca: require('element-ui/lib/locale/lang/ca')
}

View file

@ -34,7 +34,7 @@ module.exports = {
// set locale and user locale
const acceptedLanguages = req.headers['accept-language']
const supportedLanguages = ['en', 'it', 'es']
const supportedLanguages = ['en', 'it', 'es', 'ca']
acceptLanguage.languages(supportedLanguages)
req.settings.locale = acceptLanguage.get(acceptedLanguages)
req.settings.user_locale = settingsController.user_locale[req.settings.locale]