about summary refs log tree commit diff
path: root/app/javascript
diff options
context:
space:
mode:
authorKoala Yeung <koalay@gmail.com>2017-05-06 23:30:48 +0800
committerEugen Rochko <eugen@zeonfederated.com>2017-05-06 17:30:48 +0200
commitbd71327180fb4a938f5d98bbb2f1d6a624116d66 (patch)
treefd91e9ba500f69e5839e5e28dccfb2a1fbae215e /app/javascript
parent67b7d3d3b6565b88ef94b681b7f7db99b11d2435 (diff)
Fix Croatian localedata issues in mastodon.js (#2844)
* locale: added hr and oc react-intl locale data

* adds Croatian locale data in mastodon.js
* adds Occitan locale data in mastodon.js

Resolves #2667

* locale: sort locale data imports in mastodon.js

* locale: remove oc reference

* [react-intl](https://github.com/yahoo/react-intl) does not provide
  default locale data for Occitan. Hence removed from reference.
Diffstat (limited to 'app/javascript')
-rw-r--r--app/javascript/mastodon/containers/mastodon.js18
1 files changed, 10 insertions, 8 deletions
diff --git a/app/javascript/mastodon/containers/mastodon.js b/app/javascript/mastodon/containers/mastodon.js
index 4e40d73ef..648ce7cc8 100644
--- a/app/javascript/mastodon/containers/mastodon.js
+++ b/app/javascript/mastodon/containers/mastodon.js
@@ -44,25 +44,26 @@ import Mutes from '../features/mutes';
 import Report from '../features/report';
 import { IntlProvider, addLocaleData } from 'react-intl';
 import ar from 'react-intl/locale-data/ar';
-import en from 'react-intl/locale-data/en';
+import bg from 'react-intl/locale-data/bg';
 import de from 'react-intl/locale-data/de';
+import en from 'react-intl/locale-data/en';
 import eo from 'react-intl/locale-data/eo';
 import es from 'react-intl/locale-data/es';
 import fa from 'react-intl/locale-data/fa';
 import fi from 'react-intl/locale-data/fi';
 import fr from 'react-intl/locale-data/fr';
 import he from 'react-intl/locale-data/he';
+import hr from 'react-intl/locale-data/hr';
 import hu from 'react-intl/locale-data/hu';
+import id from 'react-intl/locale-data/id';
 import it from 'react-intl/locale-data/it';
 import ja from 'react-intl/locale-data/ja';
-import pt from 'react-intl/locale-data/pt';
 import nl from 'react-intl/locale-data/nl';
 import no from 'react-intl/locale-data/no';
+import pt from 'react-intl/locale-data/pt';
 import ru from 'react-intl/locale-data/ru';
 import uk from 'react-intl/locale-data/uk';
 import zh from 'react-intl/locale-data/zh';
-import bg from 'react-intl/locale-data/bg';
-import id from 'react-intl/locale-data/id';
 import getMessagesForLocale from '../locales';
 import { hydrateStore } from '../actions/store';
 import createStream from '../stream';
@@ -76,26 +77,27 @@ const browserHistory = useRouterHistory(createBrowserHistory)({
 });
 
 addLocaleData([
-  ...en,
   ...ar,
+  ...bg,
   ...de,
+  ...en,
   ...eo,
   ...es,
   ...fa,
   ...fi,
   ...fr,
   ...he,
+  ...hr,
   ...hu,
+  ...id,
   ...it,
   ...ja,
-  ...pt,
   ...nl,
   ...no,
+  ...pt,
   ...ru,
   ...uk,
   ...zh,
-  ...bg,
-  ...id,
 ]);
 
 const getTopWhenReplacing = (previous, { location }) => location && location.action === 'REPLACE' && [0, 0];