summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorCorey Hulen <corey@hulen.com>2016-01-04 08:34:23 -0600
committerCorey Hulen <corey@hulen.com>2016-01-04 08:34:23 -0600
commit8b9f9fb9c1ca384a2174c40b399fe545a7dabc0f (patch)
treed1c78ad55670b22a582d73f9057c92c1ad4a3ce3 /web
parent4a802384871ab80c433c2ae5f18da67fd9884675 (diff)
parentc81814ee1e6df1685a77b53ab506ecd2b63fbeda (diff)
downloadchat-8b9f9fb9c1ca384a2174c40b399fe545a7dabc0f.tar.gz
chat-8b9f9fb9c1ca384a2174c40b399fe545a7dabc0f.tar.bz2
chat-8b9f9fb9c1ca384a2174c40b399fe545a7dabc0f.zip
Merge pull request #1785 from mattermost/plt-1492
PLT-1492 Fix default for teammate name display setting
Diffstat (limited to 'web')
-rw-r--r--web/react/components/user_settings/user_settings_display.jsx25
1 files changed, 14 insertions, 11 deletions
diff --git a/web/react/components/user_settings/user_settings_display.jsx b/web/react/components/user_settings/user_settings_display.jsx
index c464258de..96c3985d0 100644
--- a/web/react/components/user_settings/user_settings_display.jsx
+++ b/web/react/components/user_settings/user_settings_display.jsx
@@ -141,6 +141,9 @@ export default class UserSettingsDisplay extends React.Component {
);
}
+ const showUsername = 'Show username (team default)';
+ const showNickname = 'Show nickname if one exists, otherwise show first and last name';
+ const showFullName = 'Show first and last name';
if (this.props.activeSection === 'name_format') {
const nameFormat = [false, false, false];
if (this.state.nameFormat === 'nickname_full_name') {
@@ -157,10 +160,10 @@ export default class UserSettingsDisplay extends React.Component {
<label>
<input
type='radio'
- checked={nameFormat[0]}
- onChange={this.handleNameRadio.bind(this, 'nickname_full_name')}
+ checked={nameFormat[1]}
+ onChange={this.handleNameRadio.bind(this, 'username')}
/>
- {'Show nickname if one exists, otherwise show first and last name (team default)'}
+ {showUsername}
</label>
<br/>
</div>
@@ -168,10 +171,10 @@ export default class UserSettingsDisplay extends React.Component {
<label>
<input
type='radio'
- checked={nameFormat[1]}
- onChange={this.handleNameRadio.bind(this, 'username')}
+ checked={nameFormat[0]}
+ onChange={this.handleNameRadio.bind(this, 'nickname_full_name')}
/>
- {'Show username'}
+ {showNickname}
</label>
<br/>
</div>
@@ -182,11 +185,11 @@ export default class UserSettingsDisplay extends React.Component {
checked={nameFormat[2]}
onChange={this.handleNameRadio.bind(this, 'full_name')}
/>
- {'Show first and last name'}
+ {showFullName}
</label>
<br/>
</div>
- <div><br/>{'Set what name to display in the Direct Messages list.'}</div>
+ <div><br/>{'Set how to display other user\'s names in posts and the Direct Messages list.'}</div>
</div>
];
@@ -205,11 +208,11 @@ export default class UserSettingsDisplay extends React.Component {
} else {
let describe = '';
if (this.state.nameFormat === 'username') {
- describe = 'Show username';
+ describe = showUsername;
} else if (this.state.nameFormat === 'full_name') {
- describe = 'Show first and last name';
+ describe = showFullName;
} else {
- describe = 'Show nickname if one exists, otherwise show first and last name (team default)';
+ describe = showNickname;
}
nameFormatSection = (