diff options
author | Dessalines <dessalines@users.noreply.github.com> | 2019-08-09 17:14:43 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-09 17:14:43 -0700 |
commit | 536c3f491546b4546f43a46e7a1a699ca9ac2934 (patch) | |
tree | f080c86e51b9660560ac493cb7f6d9676ea12fbe /ui/src/components/create-community.tsx | |
parent | 5a1e8aa645c9f0898e765b45c2f362308292db26 (diff) |
Adding support for internationalization / i18n (#189)
* Still not working
* Starting to work on internationalization
* Main done.
* i18n translations first pass.
* Localization testing mostly done.
* Second front end pass.
* Added a few more translations.
* Adding back end translations.
Diffstat (limited to 'ui/src/components/create-community.tsx')
-rw-r--r-- | ui/src/components/create-community.tsx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ui/src/components/create-community.tsx b/ui/src/components/create-community.tsx index c2f89eef..61245e73 100644 --- a/ui/src/components/create-community.tsx +++ b/ui/src/components/create-community.tsx @@ -2,6 +2,8 @@ import { Component } from 'inferno'; import { CommunityForm } from './community-form'; import { Community } from '../interfaces'; import { WebSocketService } from '../services'; +import { i18n } from '../i18next'; +import { T } from 'inferno-i18next'; export class CreateCommunity extends Component<any, any> { @@ -11,7 +13,7 @@ export class CreateCommunity extends Component<any, any> { } componentDidMount() { - document.title = `Create Community - ${WebSocketService.Instance.site.name}`; + document.title = `${i18n.t('create_community')} - ${WebSocketService.Instance.site.name}`; } render() { @@ -19,7 +21,7 @@ export class CreateCommunity extends Component<any, any> { <div class="container"> <div class="row"> <div class="col-12 col-lg-6 offset-lg-3 mb-4"> - <h5>Create Community</h5> + <h5><T i18nKey="create_community">#</T></h5> <CommunityForm onCreate={this.handleCommunityCreate}/> </div> </div> |