i18n string dictionaries (#3532)

* TabBar & Settings -> Views i18n enabled

* Proxy i18n

* Settings i18n

* defaultLocale

* Introduce thin Translate wrapper

* PropTypes util caters for multiples

* Translate & LanguageSelector under ui

* Update location & proptypes

* Add UI Language selector

* German settings pages

* Add German language selection

* Corrected umlaut encoding

* Lint

* Re-apply pre-merge conflict changes

* better German i18n

* Language names in locale language

* i8n -> index

* Allow for development/production operation

* Use Yahoo react-intl (as opposed to react-i18nify)

* Use default messages wih expansions

* Remove non-reused variable definitions

* Use FormattedMessage directly, opens up WebPack & Babel opportunities

* Add flat to flatten

* Extract default messages via babel

* Webpack to aggegrate i18n defaultMessage

* Re-add react-intl after merge

* Update proptype references (merge)

* Strip down external dictionary

* i18n for dapps

* Restore tests submodule

* Allow language changes to reflect

* Style updates
This commit is contained in:
Jaco Greeff
2016-12-11 17:42:35 +01:00
committed by GitHub
parent 839e3385dd
commit 885d6eaa4d
24 changed files with 783 additions and 196 deletions

View File

@@ -17,6 +17,7 @@
const webpack = require('webpack');
const path = require('path');
const ReactIntlAggregatePlugin = require('react-intl-aggregate-webpack-plugin');
const WebpackErrorNotificationPlugin = require('webpack-error-notification');
const CopyWebpackPlugin = require('copy-webpack-plugin');
const HtmlWebpackPlugin = require('html-webpack-plugin');
@@ -163,7 +164,15 @@ module.exports = {
}));
if (!isProd) {
const DEST_I18N = path.join(__dirname, '..', DEST, 'i18n');
plugins.push(
new ReactIntlAggregatePlugin({
messagesPattern: DEST_I18N + '/src/**/*.json',
aggregateOutputDir: DEST_I18N + '/i18n/',
aggregateFilename: 'en'
}),
new webpack.optimize.CommonsChunkPlugin({
filename: 'commons.[hash:10].js',
name: 'commons',