parent
1759cf8336
commit
d2ab41aea4
|
@ -41,6 +41,7 @@ import es from 'react-intl/locale-data/es';
|
||||||
import fr from 'react-intl/locale-data/fr';
|
import fr from 'react-intl/locale-data/fr';
|
||||||
import pt from 'react-intl/locale-data/pt';
|
import pt from 'react-intl/locale-data/pt';
|
||||||
import hu from 'react-intl/locale-data/hu';
|
import hu from 'react-intl/locale-data/hu';
|
||||||
|
import uk from 'react-intl/locale-data/uk';
|
||||||
import getMessagesForLocale from '../locales';
|
import getMessagesForLocale from '../locales';
|
||||||
|
|
||||||
const store = configureStore();
|
const store = configureStore();
|
||||||
|
@ -49,7 +50,7 @@ const browserHistory = useRouterHistory(createBrowserHistory)({
|
||||||
basename: '/web'
|
basename: '/web'
|
||||||
});
|
});
|
||||||
|
|
||||||
addLocaleData([...en, ...de, ...es, ...fr, ...pt, ...hu]);
|
addLocaleData([...en, ...de, ...es, ...fr, ...pt, ...hu, ...uk]);
|
||||||
|
|
||||||
const Mastodon = React.createClass({
|
const Mastodon = React.createClass({
|
||||||
|
|
||||||
|
|
|
@ -8,6 +8,7 @@ module SettingsHelper
|
||||||
pt: 'Português',
|
pt: 'Português',
|
||||||
fr: 'Français',
|
fr: 'Français',
|
||||||
hu: 'Magyar',
|
hu: 'Magyar',
|
||||||
|
uk: 'Українська',
|
||||||
}.freeze
|
}.freeze
|
||||||
|
|
||||||
def human_locale(locale)
|
def human_locale(locale)
|
||||||
|
|
|
@ -20,7 +20,7 @@ module Mastodon
|
||||||
|
|
||||||
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
||||||
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
||||||
config.i18n.available_locales = [:en, :de, :es, :pt, :fr, :hu]
|
config.i18n.available_locales = [:en, :de, :es, :pt, :fr, :hu, :uk]
|
||||||
config.i18n.default_locale = :en
|
config.i18n.default_locale = :en
|
||||||
|
|
||||||
# config.paths.add File.join('app', 'api'), glob: File.join('**', '*.rb')
|
# config.paths.add File.join('app', 'api'), glob: File.join('**', '*.rb')
|
||||||
|
|
Loading…
Reference in New Issue