summaryrefslogtreecommitdiffstats
path: root/web/react/components/email_verify.jsx
diff options
context:
space:
mode:
authorHarrison Healey <harrisonmhealey@gmail.com>2016-01-29 09:35:25 -0500
committerHarrison Healey <harrisonmhealey@gmail.com>2016-01-29 09:35:25 -0500
commit5c3fefe1a18a6b81de5d03802ee1a3f42161a38a (patch)
tree2385368448928ea3e64f3658163cf3d1b9ea5452 /web/react/components/email_verify.jsx
parentc4386652bae12c14fa704fabad066ddc07d27527 (diff)
parent94a19ae75e71b59d01a37cc1c0415d5796d45440 (diff)
downloadchat-5c3fefe1a18a6b81de5d03802ee1a3f42161a38a.tar.gz
chat-5c3fefe1a18a6b81de5d03802ee1a3f42161a38a.tar.bz2
chat-5c3fefe1a18a6b81de5d03802ee1a3f42161a38a.zip
Merge pull request #2020 from ZBoxApp/PLT-7-pages2
PLT-7: Refactoring frontend (chunk 5)
Diffstat (limited to 'web/react/components/email_verify.jsx')
-rw-r--r--web/react/components/email_verify.jsx54
1 files changed, 48 insertions, 6 deletions
diff --git a/web/react/components/email_verify.jsx b/web/react/components/email_verify.jsx
index 9c07853b7..ef1a62130 100644
--- a/web/react/components/email_verify.jsx
+++ b/web/react/components/email_verify.jsx
@@ -1,6 +1,8 @@
// Copyright (c) 2015 Mattermost, Inc. All Rights Reserved.
// See License.txt for license information.
+import {FormattedMessage, FormattedHTMLMessage} from 'mm-intl';
+
export default class EmailVerify extends React.Component {
constructor(props) {
super(props);
@@ -19,21 +21,61 @@ export default class EmailVerify extends React.Component {
var resend = '';
var resendConfirm = '';
if (this.props.isVerified === 'true') {
- title = global.window.mm_config.SiteName + ' Email Verified';
- body = <p>Your email has been verified! Click <a href={this.props.teamURL + '?email=' + this.props.userEmail}>here</a> to log in.</p>;
+ title = (
+ <FormattedMessage
+ id='email_verify.verified'
+ defaultMessage='{siteName} Email Verified'
+ values={{
+ siteName: global.window.mm_config.SiteName
+ }}
+ />
+ );
+ body = (
+ <FormattedHTMLMessage
+ id='email_verify.verifiedBody'
+ defaultMessage='<p>Your email has been verified! Click <a href={url}>here</a> to log in.</p>'
+ values={{
+ url: this.props.teamURL + '?email=' + this.props.userEmail
+ }}
+ />
+ );
} else {
- title = global.window.mm_config.SiteName + ': You are almost done';
- body = <p>Please verify your email address. Check your inbox for an email.</p>;
+ title = (
+ <FormattedMessage
+ id='email_verify.almost'
+ defaultMessage='{siteName}: You are almost done'
+ values={{
+ siteName: global.window.mm_config.SiteName
+ }}
+ />
+ );
+ body = (
+ <p>
+ <FormattedMessage
+ id='email_verify.notVerifiedBody'
+ defaultMessage='Please verify your email address. Check your inbox for an email.'
+ />
+ </p>
+ );
resend = (
<button
onClick={this.handleResend}
className='btn btn-primary'
>
- Resend Email
+ <FormattedMessage
+ id='email_verify.resend'
+ defaultMessage='Resend Email'
+ />
</button>
);
if (this.props.resendSuccess) {
- resendConfirm = <div><br /><p className='alert alert-success'><i className='fa fa-check'></i>{' Verification email sent.'}</p></div>;
+ resendConfirm = (
+ <div><br /><p className='alert alert-success'><i className='fa fa-check'></i>
+ <FormattedMessage
+ id='email_verify.sent'
+ defaultMessage=' Verification email sent.'
+ />
+ </p></div>);
}
}