From ac943f8951fe7da86aaa9f41ee879ab670786c86 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Sun, 2 Feb 2020 13:50:44 -0500 Subject: Finishing up interpolation rework. --- ui/src/components/communities.tsx | 37 +++----- ui/src/components/community-form.tsx | 24 +++-- ui/src/components/community.tsx | 17 ++-- ui/src/components/create-community.tsx | 5 +- ui/src/components/create-post.tsx | 5 +- ui/src/components/inbox.tsx | 42 +++------ ui/src/components/login.tsx | 45 +++++----- ui/src/components/main.tsx | 84 ++++++------------ ui/src/components/modlog.tsx | 15 ++-- ui/src/components/navbar.tsx | 13 ++- ui/src/components/password_change.tsx | 9 +- ui/src/components/post-form.tsx | 45 +++++----- ui/src/components/post-listing.tsx | 68 +++++++------- ui/src/components/post-listings.tsx | 9 +- ui/src/components/post.tsx | 14 ++- ui/src/components/search.tsx | 45 +++------- ui/src/components/setup.tsx | 23 +++-- ui/src/components/sidebar.tsx | 52 +++++------ ui/src/components/site-form.tsx | 27 +++--- ui/src/components/sort-select.tsx | 33 ++----- ui/src/components/user.tsx | 156 ++++++++++++--------------------- 21 files changed, 296 insertions(+), 472 deletions(-) (limited to 'ui/src') diff --git a/ui/src/components/communities.tsx b/ui/src/components/communities.tsx index eef39ccf..8d130ae7 100644 --- a/ui/src/components/communities.tsx +++ b/ui/src/components/communities.tsx @@ -15,7 +15,6 @@ import { import { WebSocketService } from '../services'; import { wsJsonToRes, toast } from '../utils'; import { i18n } from '../i18next'; -import { T } from 'inferno-i18next'; declare const Sortable: any; @@ -76,37 +75,27 @@ export class Communities extends Component { return (
{this.state.loading ? ( -

+

-

+
) : (
-
- { i18n.t('list_of_communities') } -
+
{i18n.t('list_of_communities')}
- - - - + + + + @@ -139,7 +128,7 @@ export class Communities extends Component { this.handleUnsubscribe )} > - # + {i18n.t('unsubscribe')} ) : ( { this.handleSubscribe )} > - { i18n.t('subscribe') } + {i18n.t('subscribe')} )} @@ -173,7 +162,7 @@ export class Communities extends Component { class="btn btn-sm btn-secondary mr-1" onClick={linkEvent(this, this.prevPage)} > - { i18n.t('prev') } + {i18n.t('prev')} )} @@ -182,7 +171,7 @@ export class Communities extends Component { class="btn btn-sm btn-secondary" onClick={linkEvent(this, this.nextPage)} > - { i18n.t('next') } + {i18n.t('next')} )} diff --git a/ui/src/components/community-form.tsx b/ui/src/components/community-form.tsx index 46fc4185..aaa3e6c4 100644 --- a/ui/src/components/community-form.tsx +++ b/ui/src/components/community-form.tsx @@ -21,7 +21,6 @@ import { import Tribute from 'tributejs/src/Tribute.js'; import autosize from 'autosize'; import { i18n } from '../i18next'; -import { T } from 'inferno-i18next'; import { Community } from '../interfaces'; @@ -108,8 +107,8 @@ export class CommunityForm extends Component< return (
-
- { i18n.t('name') } - - { i18n.t('title') } - - { i18n.t('category') } - - { i18n.t('subscribers') } - {i18n.t('name')}{i18n.t('title')}{i18n.t('category')}{i18n.t('subscribers')} - { i18n.t('posts') } + {i18n.t('posts')} - { i18n.t('comments') } + {i18n.t('comments')}