Skip to content

Commit

Permalink
optimize translation
Browse files Browse the repository at this point in the history
  • Loading branch information
mashirozx committed Aug 20, 2020
1 parent 94179a4 commit 2a5e159
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions app/javascript/mastodon/components/status_content.js
Expand Up @@ -251,7 +251,7 @@ export default class StatusContent extends React.PureComponent {
</button>
);

const toggleTranslation = !this.state.hideTranslation ? <FormattedMessage id='status.hide_translation' defaultMessage='Translate toot' /> : <FormattedMessage id='status.show_translation' defaultMessage='Hide translation' />;
const toggleTranslation = !this.state.hideTranslation ? <FormattedMessage id='status.hide_translation' defaultMessage='Hide translation' /> : <FormattedMessage id='status.show_translation' defaultMessage='Translate toot' />;

const readMoreButton = (
<button className='status__content__read-more-button' onClick={this.props.onClick} key='read-more'>
Expand All @@ -260,6 +260,7 @@ export default class StatusContent extends React.PureComponent {
);

const translationContainer = (
getLocale().localeData[0].locale !== status.get('language') ?
<React.Fragment>
<button
tabIndex='-1' className={'status__content__show-translation-button'}
Expand Down Expand Up @@ -298,7 +299,7 @@ export default class StatusContent extends React.PureComponent {
<p className='translation-content'>{this.state.translation}</p>
</section>
</div>
</React.Fragment>
</React.Fragment> : null
);

if (status.get('spoiler_text').length > 0) {
Expand Down

0 comments on commit 2a5e159

Please sign in to comment.