summaryrefslogtreecommitdiffstats
path: root/web/react/components
diff options
context:
space:
mode:
Diffstat (limited to 'web/react/components')
-rw-r--r--web/react/components/email_verify.jsx6
-rw-r--r--web/react/components/find_team.jsx7
-rw-r--r--web/react/components/get_link_modal.jsx5
-rw-r--r--web/react/components/invite_member_modal.jsx96
-rw-r--r--web/react/components/login.jsx7
-rw-r--r--web/react/components/navbar_dropdown.jsx5
-rw-r--r--web/react/components/password_reset_form.jsx3
-rw-r--r--web/react/components/post_list.jsx6
-rw-r--r--web/react/components/setting_picture.jsx4
-rw-r--r--web/react/components/sidebar_header.jsx3
-rw-r--r--web/react/components/sidebar_right_menu.jsx5
-rw-r--r--web/react/components/signup_team_complete.jsx10
-rw-r--r--web/react/components/signup_user_complete.jsx9
-rw-r--r--web/react/components/team_general_tab.jsx9
-rw-r--r--web/react/components/team_signup_allowed_domains_page.jsx7
-rw-r--r--web/react/components/team_signup_choose_auth.jsx7
-rw-r--r--web/react/components/team_signup_display_name_page.jsx5
-rw-r--r--web/react/components/team_signup_password_page.jsx5
-rw-r--r--web/react/components/team_signup_send_invites_page.jsx15
-rw-r--r--web/react/components/team_signup_url_page.jsx13
-rw-r--r--web/react/components/team_signup_username_page.jsx3
-rw-r--r--web/react/components/team_signup_welcome_page.jsx3
-rw-r--r--web/react/components/team_signup_with_email.jsx3
-rw-r--r--web/react/components/team_signup_with_sso.jsx5
-rw-r--r--web/react/components/user_profile.jsx3
-rw-r--r--web/react/components/user_settings_appearance.jsx17
-rw-r--r--web/react/components/user_settings_notifications.jsx3
-rw-r--r--web/react/components/view_image.jsx3
28 files changed, 101 insertions, 166 deletions
diff --git a/web/react/components/email_verify.jsx b/web/react/components/email_verify.jsx
index 95948c8dd..92123956f 100644
--- a/web/react/components/email_verify.jsx
+++ b/web/react/components/email_verify.jsx
@@ -1,8 +1,6 @@
// Copyright (c) 2015 Spinpunch, Inc. All Rights Reserved.
// See License.txt for license information.
-import {config} from '../utils/config.js';
-
export default class EmailVerify extends React.Component {
constructor(props) {
super(props);
@@ -19,10 +17,10 @@ export default class EmailVerify extends React.Component {
var body = '';
var resend = '';
if (this.props.isVerified === 'true') {
- title = config.SiteName + ' Email Verified';
+ title = global.window.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>;
} else {
- title = config.SiteName + ' Email Not Verified';
+ title = global.window.config.SiteName + ' Email Not Verified';
body = <p>Please verify your email address. Check your inbox for an email.</p>;
resend = (
<button
diff --git a/web/react/components/find_team.jsx b/web/react/components/find_team.jsx
index 52988886c..eb2683a88 100644
--- a/web/react/components/find_team.jsx
+++ b/web/react/components/find_team.jsx
@@ -3,7 +3,6 @@
var utils = require('../utils/utils.jsx');
var client = require('../utils/client.jsx');
-import {strings} from '../utils/config.js';
export default class FindTeam extends React.Component {
constructor(props) {
@@ -51,8 +50,8 @@ export default class FindTeam extends React.Component {
if (this.state.sent) {
return (
<div>
- <h4>{'Find Your ' + utils.toTitleCase(strings.Team)}</h4>
- <p>{'An email was sent with links to any ' + strings.TeamPlural + ' to which you are a member.'}</p>
+ <h4>{'Find Your team'}</h4>
+ <p>{'An email was sent with links to any teams to which you are a member.'}</p>
</div>
);
}
@@ -61,7 +60,7 @@ export default class FindTeam extends React.Component {
<div>
<h4>Find Your Team</h4>
<form onSubmit={this.handleSubmit}>
- <p>{'Get an email with links to any ' + strings.TeamPlural + ' to which you are a member.'}</p>
+ <p>{'Get an email with links to any teams to which you are a member.'}</p>
<div className='form-group'>
<label className='control-label'>Email</label>
<div className={emailErrorClass}>
diff --git a/web/react/components/get_link_modal.jsx b/web/react/components/get_link_modal.jsx
index 1f25ea0b7..5d8b13f00 100644
--- a/web/react/components/get_link_modal.jsx
+++ b/web/react/components/get_link_modal.jsx
@@ -2,7 +2,6 @@
// See License.txt for license information.
var UserStore = require('../stores/user_store.jsx');
-import {strings} from '../utils/config.js';
export default class GetLinkModal extends React.Component {
constructor(props) {
@@ -76,9 +75,9 @@ export default class GetLinkModal extends React.Component {
</div>
<div className='modal-body'>
<p>
- Send {strings.Team + 'mates'} the link below for them to sign-up to this {strings.Team} site.
+ Send teammates the link below for them to sign-up to this team site.
<br /><br />
- Be careful not to share this link publicly, since anyone with the link can join your {strings.Team}.
+ Be careful not to share this link publicly, since anyone with the link can join your team.
</p>
<textarea
className='form-control no-resize'
diff --git a/web/react/components/invite_member_modal.jsx b/web/react/components/invite_member_modal.jsx
index c1cfa7800..7f576626f 100644
--- a/web/react/components/invite_member_modal.jsx
+++ b/web/react/components/invite_member_modal.jsx
@@ -6,7 +6,6 @@ var ConfigStore = require('../stores/config_store.jsx');
var Client = require('../utils/client.jsx');
var UserStore = require('../stores/user_store.jsx');
var ConfirmModal = require('./confirm_modal.jsx');
-import {config} from '../utils/config.js';
export default class InviteMemberModal extends React.Component {
constructor(props) {
@@ -79,23 +78,9 @@ export default class InviteMemberModal extends React.Component {
emailErrors[index] = '';
}
- if (config.AllowInviteNames) {
- invite.firstName = React.findDOMNode(this.refs['first_name' + index]).value.trim();
- if (!invite.firstName && config.RequireInviteNames) {
- firstNameErrors[index] = 'This is a required field';
- valid = false;
- } else {
- firstNameErrors[index] = '';
- }
+ invite.firstName = React.findDOMNode(this.refs['first_name' + index]).value.trim();
- invite.lastName = React.findDOMNode(this.refs['last_name' + index]).value.trim();
- if (!invite.lastName && config.RequireInviteNames) {
- lastNameErrors[index] = 'This is a required field';
- valid = false;
- } else {
- lastNameErrors[index] = '';
- }
- }
+ invite.lastName = React.findDOMNode(this.refs['last_name' + index]).value.trim();
invites.push(invite);
}
@@ -143,10 +128,8 @@ export default class InviteMemberModal extends React.Component {
for (var i = 0; i < inviteIds.length; i++) {
var index = inviteIds[i];
React.findDOMNode(this.refs['email' + index]).value = '';
- if (config.AllowInviteNames) {
- React.findDOMNode(this.refs['first_name' + index]).value = '';
- React.findDOMNode(this.refs['last_name' + index]).value = '';
- }
+ React.findDOMNode(this.refs['first_name' + index]).value = '';
+ React.findDOMNode(this.refs['last_name' + index]).value = '';
}
this.setState({
@@ -210,44 +193,43 @@ export default class InviteMemberModal extends React.Component {
}
var nameFields = null;
- if (config.AllowInviteNames) {
- var firstNameClass = 'form-group';
- if (firstNameError) {
- firstNameClass += ' has-error';
- }
- var lastNameClass = 'form-group';
- if (lastNameError) {
- lastNameClass += ' has-error';
- }
- nameFields = (<div className='row--invite'>
- <div className='col-sm-6'>
- <div className={firstNameClass}>
- <input
- type='text'
- className='form-control'
- ref={'first_name' + index}
- placeholder='First name'
- maxLength='64'
- disabled={!this.state.emailEnabled}
- />
- {firstNameError}
- </div>
+
+ var firstNameClass = 'form-group';
+ if (firstNameError) {
+ firstNameClass += ' has-error';
+ }
+ var lastNameClass = 'form-group';
+ if (lastNameError) {
+ lastNameClass += ' has-error';
+ }
+ nameFields = (<div className='row--invite'>
+ <div className='col-sm-6'>
+ <div className={firstNameClass}>
+ <input
+ type='text'
+ className='form-control'
+ ref={'first_name' + index}
+ placeholder='First name'
+ maxLength='64'
+ disabled={!this.state.emailEnabled}
+ />
+ {firstNameError}
</div>
- <div className='col-sm-6'>
- <div className={lastNameClass}>
- <input
- type='text'
- className='form-control'
- ref={'last_name' + index}
- placeholder='Last name'
- maxLength='64'
- disabled={!this.state.emailEnabled}
- />
- {lastNameError}
- </div>
+ </div>
+ <div className='col-sm-6'>
+ <div className={lastNameClass}>
+ <input
+ type='text'
+ className='form-control'
+ ref={'last_name' + index}
+ placeholder='Last name'
+ maxLength='64'
+ disabled={!this.state.emailEnabled}
+ />
+ {lastNameError}
</div>
- </div>);
- }
+ </div>
+ </div>);
inviteSections[index] = (
<div key={'key' + index}>
diff --git a/web/react/components/login.jsx b/web/react/components/login.jsx
index b20c62833..ffc07a4dd 100644
--- a/web/react/components/login.jsx
+++ b/web/react/components/login.jsx
@@ -6,7 +6,6 @@ const Client = require('../utils/client.jsx');
const UserStore = require('../stores/user_store.jsx');
const BrowserStore = require('../stores/browser_store.jsx');
const Constants = require('../utils/constants.jsx');
-import {config, strings} from '../utils/config.js';
export default class Login extends React.Component {
constructor(props) {
@@ -177,7 +176,7 @@ export default class Login extends React.Component {
<div className='signup-team__container'>
<h5 className='margin--less'>Sign in to:</h5>
<h2 className='signup-team__name'>{teamDisplayName}</h2>
- <h2 className='signup-team__subdomain'>on {config.SiteName}</h2>
+ <h2 className='signup-team__subdomain'>on {global.window.config.SiteName}</h2>
<form onSubmit={this.handleSubmit}>
<div className={'form-group' + errorClass}>
{serverError}
@@ -185,11 +184,11 @@ export default class Login extends React.Component {
{loginMessage}
{emailSignup}
<div className='form-group margin--extra form-group--small'>
- <span><a href='/find_team'>{'Find other ' + strings.TeamPlural}</a></span>
+ <span><a href='/find_team'>{'Find other teams'}</a></span>
</div>
{forgotPassword}
<div className='margin--extra'>
- <span>{'Want to create your own ' + strings.Team + '? '}
+ <span>{'Want to create your own team? '}
<a
href='/'
className='signup-team-login'
diff --git a/web/react/components/navbar_dropdown.jsx b/web/react/components/navbar_dropdown.jsx
index 99cdfa1ad..b7566cfb9 100644
--- a/web/react/components/navbar_dropdown.jsx
+++ b/web/react/components/navbar_dropdown.jsx
@@ -7,7 +7,6 @@ var UserStore = require('../stores/user_store.jsx');
var TeamStore = require('../stores/team_store.jsx');
var Constants = require('../utils/constants.jsx');
-import {config} from '../utils/config.js';
function getStateFromStores() {
return {teams: UserStore.getTeams(), currentTeam: TeamStore.getCurrent()};
@@ -188,7 +187,7 @@ export default class NavbarDropdown extends React.Component {
<li>
<a
target='_blank'
- href={config.HelpLink}
+ href='/static/help/help.html'
>
Help
</a>
@@ -196,7 +195,7 @@ export default class NavbarDropdown extends React.Component {
<li>
<a
target='_blank'
- href={config.ReportProblemLink}
+ href='/static/help/report_problem.html'
>
Report a Problem
</a>
diff --git a/web/react/components/password_reset_form.jsx b/web/react/components/password_reset_form.jsx
index 1b579efbc..dae582627 100644
--- a/web/react/components/password_reset_form.jsx
+++ b/web/react/components/password_reset_form.jsx
@@ -2,7 +2,6 @@
// See License.txt for license information.
var client = require('../utils/client.jsx');
-import {config} from '../utils/config.js';
export default class PasswordResetForm extends React.Component {
constructor(props) {
@@ -62,7 +61,7 @@ export default class PasswordResetForm extends React.Component {
<div className='signup-team__container'>
<h3>Password Reset</h3>
<form onSubmit={this.handlePasswordReset}>
- <p>{'Enter a new password for your ' + this.props.teamDisplayName + ' ' + config.SiteName + ' account.'}</p>
+ <p>{'Enter a new password for your ' + this.props.teamDisplayName + ' ' + global.window.config.SiteName + ' account.'}</p>
<div className={formClass}>
<input
type='password'
diff --git a/web/react/components/post_list.jsx b/web/react/components/post_list.jsx
index e6aa3f8df..faa5e5f0b 100644
--- a/web/react/components/post_list.jsx
+++ b/web/react/components/post_list.jsx
@@ -15,8 +15,6 @@ var AppDispatcher = require('../dispatcher/app_dispatcher.jsx');
var Constants = require('../utils/constants.jsx');
var ActionTypes = Constants.ActionTypes;
-import {strings} from '../utils/config.js';
-
export default class PostList extends React.Component {
constructor(props) {
super(props);
@@ -347,7 +345,7 @@ export default class PostList extends React.Component {
return (
<div className='channel-intro'>
- <p className='channel-intro-text'>{'This is the start of your private message history with this ' + strings.Team + 'mate. Private messages and files shared here are not shown to people outside this area.'}</p>
+ <p className='channel-intro-text'>{'This is the start of your private message history with this teammate. Private messages and files shared here are not shown to people outside this area.'}</p>
</div>
);
}
@@ -369,7 +367,7 @@ export default class PostList extends React.Component {
<p className='channel-intro__content'>
Welcome to {channel.display_name}!
<br/><br/>
- This is the first channel {strings.Team}mates see when they
+ This is the first channel teammates see when they
<br/>
sign up - use it for posting updates everyone needs to know.
<br/><br/>
diff --git a/web/react/components/setting_picture.jsx b/web/react/components/setting_picture.jsx
index a53112651..ddad4fd53 100644
--- a/web/react/components/setting_picture.jsx
+++ b/web/react/components/setting_picture.jsx
@@ -1,8 +1,6 @@
// Copyright (c) 2015 Spinpunch, Inc. All Rights Reserved.
// See License.txt for license information.
-import {config} from '../utils/config.js';
-
export default class SettingPicture extends React.Component {
constructor(props) {
super(props);
@@ -81,7 +79,7 @@ export default class SettingPicture extends React.Component {
>Save</a>
);
}
- var helpText = 'Upload a profile picture in either JPG or PNG format, at least ' + config.ProfileWidth + 'px in width and ' + config.ProfileHeight + 'px height.';
+ var helpText = 'Upload a profile picture in either JPG or PNG format, at least ' + global.window.config.ProfileWidth + 'px in width and ' + global.window.config.ProfileHeight + 'px height.';
var self = this;
return (
diff --git a/web/react/components/sidebar_header.jsx b/web/react/components/sidebar_header.jsx
index 0056d7a2f..959411f1e 100644
--- a/web/react/components/sidebar_header.jsx
+++ b/web/react/components/sidebar_header.jsx
@@ -3,7 +3,6 @@
var NavbarDropdown = require('./navbar_dropdown.jsx');
var UserStore = require('../stores/user_store.jsx');
-import {config} from '../utils/config.js';
export default class SidebarHeader extends React.Component {
constructor(props) {
@@ -59,7 +58,7 @@ export default class SidebarHeader extends React.Component {
}
SidebarHeader.defaultProps = {
- teamDisplayName: config.SiteName,
+ teamDisplayName: global.window.config.SiteName,
teamType: ''
};
SidebarHeader.propTypes = {
diff --git a/web/react/components/sidebar_right_menu.jsx b/web/react/components/sidebar_right_menu.jsx
index bd10a6ef1..5ecd502ba 100644
--- a/web/react/components/sidebar_right_menu.jsx
+++ b/web/react/components/sidebar_right_menu.jsx
@@ -4,7 +4,6 @@
var UserStore = require('../stores/user_store.jsx');
var client = require('../utils/client.jsx');
var utils = require('../utils/utils.jsx');
-import {config} from '../utils/config.js';
export default class SidebarRightMenu extends React.Component {
constructor(props) {
@@ -75,8 +74,8 @@ export default class SidebarRightMenu extends React.Component {
}
var siteName = '';
- if (config.SiteName != null) {
- siteName = config.SiteName;
+ if (global.window.config.SiteName != null) {
+ siteName = global.window.config.SiteName;
}
var teamDisplayName = siteName;
if (this.props.teamDisplayName) {
diff --git a/web/react/components/signup_team_complete.jsx b/web/react/components/signup_team_complete.jsx
index dc0d1d376..9c03c5c2f 100644
--- a/web/react/components/signup_team_complete.jsx
+++ b/web/react/components/signup_team_complete.jsx
@@ -4,7 +4,6 @@
var WelcomePage = require('./team_signup_welcome_page.jsx');
var TeamDisplayNamePage = require('./team_signup_display_name_page.jsx');
var TeamURLPage = require('./team_signup_url_page.jsx');
-var AllowedDomainsPage = require('./team_signup_allowed_domains_page.jsx');
var SendInivtesPage = require('./team_signup_send_invites_page.jsx');
var UsernamePage = require('./team_signup_username_page.jsx');
var PasswordPage = require('./team_signup_password_page.jsx');
@@ -70,15 +69,6 @@ export default class SignupTeamComplete extends React.Component {
);
}
- if (this.state.wizard === 'allowed_domains') {
- return (
- <AllowedDomainsPage
- state={this.state}
- updateParent={this.updateParent}
- />
- );
- }
-
if (this.state.wizard === 'send_invites') {
return (
<SendInivtesPage
diff --git a/web/react/components/signup_user_complete.jsx b/web/react/components/signup_user_complete.jsx
index 6e71eae32..e021c9cd1 100644
--- a/web/react/components/signup_user_complete.jsx
+++ b/web/react/components/signup_user_complete.jsx
@@ -6,7 +6,6 @@ var client = require('../utils/client.jsx');
var UserStore = require('../stores/user_store.jsx');
var BrowserStore = require('../stores/browser_store.jsx');
var Constants = require('../utils/constants.jsx');
-import {config} from '../utils/config.js';
export default class SignupUserComplete extends React.Component {
constructor(props) {
@@ -136,7 +135,7 @@ export default class SignupUserComplete extends React.Component {
// set up the email entry and hide it if an email was provided
var yourEmailIs = '';
if (this.state.user.email) {
- yourEmailIs = <span>Your email address is {this.state.user.email}. You'll use this address to sign in to {config.SiteName}.</span>;
+ yourEmailIs = <span>Your email address is {this.state.user.email}. You'll use this address to sign in to {global.window.config.SiteName}.</span>;
}
var emailContainerStyle = 'margin--extra';
@@ -238,8 +237,8 @@ export default class SignupUserComplete extends React.Component {
}
var termsDisclaimer = null;
- if (config.ShowTermsDuringSignup) {
- termsDisclaimer = <p>By creating an account and using Mattermost you are agreeing to our <a href={config.TermsLink}>Terms of Service</a>. If you do not agree, you cannot use this service.</p>;
+ if (global.window.config.ShowTermsDuringSignup) {
+ termsDisclaimer = <p>By creating an account and using Mattermost you are agreeing to our <a href='/static/help/terms.html'>Terms of Service</a>. If you do not agree, you cannot use this service.</p>;
}
return (
@@ -251,7 +250,7 @@ export default class SignupUserComplete extends React.Component {
/>
<h5 className='margin--less'>Welcome to:</h5>
<h2 className='signup-team__name'>{this.props.teamDisplayName}</h2>
- <h2 className='signup-team__subdomain'>on {config.SiteName}</h2>
+ <h2 className='signup-team__subdomain'>on {global.window.config.SiteName}</h2>
<h4 className='color--light'>Let's create your account</h4>
{signupMessage}
{emailSignup}
diff --git a/web/react/components/team_general_tab.jsx b/web/react/components/team_general_tab.jsx
index 25139bb95..ca438df78 100644
--- a/web/react/components/team_general_tab.jsx
+++ b/web/react/components/team_general_tab.jsx
@@ -6,7 +6,6 @@ const SettingItemMax = require('./setting_item_max.jsx');
const Client = require('../utils/client.jsx');
const Utils = require('../utils/utils.jsx');
-import {strings} from '../utils/config.js';
export default class GeneralTab extends React.Component {
constructor(props) {
@@ -30,7 +29,7 @@ export default class GeneralTab extends React.Component {
state.clientError = 'This field is required';
valid = false;
} else if (name === this.props.teamDisplayName) {
- state.clientError = 'Please choose a new name for your ' + strings.Team;
+ state.clientError = 'Please choose a new name for your team';
valid = false;
} else {
state.clientError = '';
@@ -99,7 +98,7 @@ export default class GeneralTab extends React.Component {
if (this.props.activeSection === 'name') {
let inputs = [];
- let teamNameLabel = Utils.toTitleCase(strings.Team) + ' Name';
+ let teamNameLabel = 'Team Name';
if (Utils.isMobile()) {
teamNameLabel = '';
}
@@ -123,7 +122,7 @@ export default class GeneralTab extends React.Component {
nameSection = (
<SettingItemMax
- title={`${Utils.toTitleCase(strings.Team)} Name`}
+ title={`Team Name`}
inputs={inputs}
submit={this.handleNameSubmit}
server_error={serverError}
@@ -136,7 +135,7 @@ export default class GeneralTab extends React.Component {
nameSection = (
<SettingItemMin
- title={`${Utils.toTitleCase(strings.Team)} Name`}
+ title={`Team Name`}
describe={describe}
updateSection={this.onUpdateSection}
/>
diff --git a/web/react/components/team_signup_allowed_domains_page.jsx b/web/react/components/team_signup_allowed_domains_page.jsx
index 721fa142a..ad15383a3 100644
--- a/web/react/components/team_signup_allowed_domains_page.jsx
+++ b/web/react/components/team_signup_allowed_domains_page.jsx
@@ -2,7 +2,6 @@
// See License.txt for license information.
var Client = require('../utils/client.jsx');
-import {strings} from '../utils/config.js';
export default class TeamSignupAllowedDomainsPage extends React.Component {
constructor(props) {
@@ -77,12 +76,12 @@ export default class TeamSignupAllowedDomainsPage extends React.Component {
ref='allow'
defaultChecked={true}
/>
- {' Allow sign up and ' + strings.Team + ' discovery with a ' + strings.Company + ' email address.'}
+ {' Allow sign up and team discovery with a company email address.'}
</label>
</div>
</p>
- <p>{'Check this box to allow your ' + strings.Team + ' members to sign up using their ' + strings.Company + ' email addresses if you share the same domain--otherwise, you need to invite everyone yourself.'}</p>
- <h4>{'Your ' + strings.Team + '\'s domain for emails'}</h4>
+ <p>{'Check this box to allow your team members to sign up using their company email addresses if you share the same domain--otherwise, you need to invite everyone yourself.'}</p>
+ <h4>{'Your team\'s domain for emails'}</h4>
<div className={nameDivClass}>
<div className='row'>
<div className='col-sm-9'>
diff --git a/web/react/components/team_signup_choose_auth.jsx b/web/react/components/team_signup_choose_auth.jsx
index acce6ab49..d3107c5c7 100644
--- a/web/react/components/team_signup_choose_auth.jsx
+++ b/web/react/components/team_signup_choose_auth.jsx
@@ -2,7 +2,6 @@
// See License.txt for license information.
var Constants = require('../utils/constants.jsx');
-import {strings} from '../utils/config.js';
export default class ChooseAuthPage extends React.Component {
constructor(props) {
@@ -24,7 +23,7 @@ export default class ChooseAuthPage extends React.Component {
}
>
<span className='icon' />
- <span>Create new {strings.Team} with GitLab Account</span>
+ <span>Create new team with GitLab Account</span>
</a>
);
}
@@ -42,7 +41,7 @@ export default class ChooseAuthPage extends React.Component {
}
>
<span className='fa fa-envelope' />
- <span>Create new {strings.Team} with email address</span>
+ <span>Create new team with email address</span>
</a>
);
}
@@ -55,7 +54,7 @@ export default class ChooseAuthPage extends React.Component {
<div>
{buttons}
<div className='form-group margin--extra-2x'>
- <span><a href='/find_team'>{'Find my ' + strings.Team}</a></span>
+ <span><a href='/find_team'>{'Find my team'}</a></span>
</div>
</div>
);
diff --git a/web/react/components/team_signup_display_name_page.jsx b/web/react/components/team_signup_display_name_page.jsx
index 1849f8222..c0d0ed366 100644
--- a/web/react/components/team_signup_display_name_page.jsx
+++ b/web/react/components/team_signup_display_name_page.jsx
@@ -3,7 +3,6 @@
var utils = require('../utils/utils.jsx');
var client = require('../utils/client.jsx');
-import {strings} from '../utils/config.js';
export default class TeamSignupDisplayNamePage extends React.Component {
constructor(props) {
@@ -54,7 +53,7 @@ export default class TeamSignupDisplayNamePage extends React.Component {
className='signup-team-logo'
src='/static/images/logo.png'
/>
- <h2>{utils.toTitleCase(strings.Team) + ' Name'}</h2>
+ <h2>{'Team Name'}</h2>
<div className={nameDivClass}>
<div className='row'>
<div className='col-sm-9'>
@@ -73,7 +72,7 @@ export default class TeamSignupDisplayNamePage extends React.Component {
{nameError}
</div>
<div>
- {'Name your ' + strings.Team + ' in any language. Your ' + strings.Team + ' name shows in menus and headings.'}
+ {'Name your team in any language. Your team name shows in menus and headings.'}
</div>
<button
type='submit'
diff --git a/web/react/components/team_signup_password_page.jsx b/web/react/components/team_signup_password_page.jsx
index aa402846b..b26d9f6ce 100644
--- a/web/react/components/team_signup_password_page.jsx
+++ b/web/react/components/team_signup_password_page.jsx
@@ -4,7 +4,6 @@
var Client = require('../utils/client.jsx');
var BrowserStore = require('../stores/browser_store.jsx');
var UserStore = require('../stores/user_store.jsx');
-import {strings, config} from '../utils/config.js';
export default class TeamSignupPasswordPage extends React.Component {
constructor(props) {
@@ -123,13 +122,13 @@ export default class TeamSignupPasswordPage extends React.Component {
type='submit'
className='btn btn-primary margin--extra'
id='finish-button'
- data-loading-text={'<span class=\'glyphicon glyphicon-refresh glyphicon-refresh-animate\'></span> Creating ' + strings.Team + '...'}
+ data-loading-text={'<span class=\'glyphicon glyphicon-refresh glyphicon-refresh-animate\'></span> Creating team...'}
onClick={this.submitNext}
>
Finish
</button>
</div>
- <p>By proceeding to create your account and use {config.SiteName}, you agree to our <a href={config.TermsLink}>Terms of Service</a> and <a href={config.PrivacyLink}>Privacy Policy</a>. If you do not agree, you cannot use {config.SiteName}.</p>
+ <p>By proceeding to create your account and use {global.window.config.SiteName}, you agree to our <a href='/static/help/terms.html'>Terms of Service</a> and <a href='/static/help/privacy.html'>Privacy Policy</a>. If you do not agree, you cannot use {global.window.config.SiteName}.</p>
<div className='margin--extra'>
<a
href='#'
diff --git a/web/react/components/team_signup_send_invites_page.jsx b/web/react/components/team_signup_send_invites_page.jsx
index 11a9980d7..e49534f5f 100644
--- a/web/react/components/team_signup_send_invites_page.jsx
+++ b/web/react/components/team_signup_send_invites_page.jsx
@@ -2,10 +2,8 @@
// See License.txt for license information.
var EmailItem = require('./team_signup_email_item.jsx');
-var Utils = require('../utils/utils.jsx');
var ConfigStore = require('../stores/config_store.jsx');
var Client = require('../utils/client.jsx');
-import {strings, config} from '../utils/config.js';
export default class TeamSignupSendInvitesPage extends React.Component {
constructor(props) {
@@ -26,12 +24,7 @@ export default class TeamSignupSendInvitesPage extends React.Component {
}
submitBack(e) {
e.preventDefault();
-
- if (config.AllowSignupDomainsWizard) {
- this.props.state.wizard = 'allowed_domains';
- } else {
- this.props.state.wizard = 'team_url';
- }
+ this.props.state.wizard = 'team_url';
this.props.updateParent(this.props.state);
}
@@ -138,7 +131,7 @@ export default class TeamSignupSendInvitesPage extends React.Component {
bottomContent = (
<p className='color--light'>
- {'if you prefer, you can invite ' + strings.Team + ' members later'}
+ {'if you prefer, you can invite team members later'}
<br />
{' and '}
<a
@@ -153,7 +146,7 @@ export default class TeamSignupSendInvitesPage extends React.Component {
} else {
content = (
<div className='form-group color--light'>
- {'Email is currently disabled for your ' + strings.Team + ', and emails cannot be sent. Contact your system administrator to enable email and email invitations.'}
+ {'Email is currently disabled for your team, and emails cannot be sent. Contact your system administrator to enable email and email invitations.'}
</div>
);
}
@@ -165,7 +158,7 @@ export default class TeamSignupSendInvitesPage extends React.Component {
className='signup-team-logo'
src='/static/images/logo.png'
/>
- <h2>{'Invite ' + Utils.toTitleCase(strings.Team) + ' Members'}</h2>
+ <h2>{'Invite Team Members'}</h2>
{content}
<div className='form-group'>
<button
diff --git a/web/react/components/team_signup_url_page.jsx b/web/react/components/team_signup_url_page.jsx
index ffe9d9fe8..1b722d611 100644
--- a/web/react/components/team_signup_url_page.jsx
+++ b/web/react/components/team_signup_url_page.jsx
@@ -4,7 +4,6 @@
const Utils = require('../utils/utils.jsx');
const Client = require('../utils/client.jsx');
const Constants = require('../utils/constants.jsx');
-import {strings, config} from '../utils/config.js';
export default class TeamSignupUrlPage extends React.Component {
constructor(props) {
@@ -51,12 +50,8 @@ export default class TeamSignupUrlPage extends React.Component {
Client.findTeamByName(name,
function success(data) {
if (!data) {
- if (config.AllowSignupDomainsWizard) {
- this.props.state.wizard = 'allowed_domains';
- } else {
- this.props.state.wizard = 'send_invites';
- this.props.state.team.type = 'O';
- }
+ this.props.state.wizard = 'send_invites';
+ this.props.state.team.type = 'O';
this.props.state.team.name = name;
this.props.updateParent(this.props.state);
@@ -97,7 +92,7 @@ export default class TeamSignupUrlPage extends React.Component {
className='signup-team-logo'
src='/static/images/logo.png'
/>
- <h2>{`${Utils.toTitleCase(strings.Team)} URL`}</h2>
+ <h2>{`Team URL`}</h2>
<div className={nameDivClass}>
<div className='row'>
<div className='col-sm-11'>
@@ -124,7 +119,7 @@ export default class TeamSignupUrlPage extends React.Component {
</div>
{nameError}
</div>
- <p>{`Choose the web address of your new ${strings.Team}:`}</p>
+ <p>{`Choose the web address of your new team:`}</p>
<ul className='color--light'>
<li>Short and memorable is best</li>
<li>Use lowercase letters, numbers and dashes</li>
diff --git a/web/react/components/team_signup_username_page.jsx b/web/react/components/team_signup_username_page.jsx
index 984c7afab..0053b011d 100644
--- a/web/react/components/team_signup_username_page.jsx
+++ b/web/react/components/team_signup_username_page.jsx
@@ -3,7 +3,6 @@
var Utils = require('../utils/utils.jsx');
var Client = require('../utils/client.jsx');
-import {strings} from '../utils/config.js';
export default class TeamSignupUsernamePage extends React.Component {
constructor(props) {
@@ -55,7 +54,7 @@ export default class TeamSignupUsernamePage extends React.Component {
src='/static/images/logo.png'
/>
<h2 className='margin--less'>Your username</h2>
- <h5 className='color--light'>{'Select a memorable username that makes it easy for ' + strings.Team + 'mates to identify you:'}</h5>
+ <h5 className='color--light'>{'Select a memorable username that makes it easy for teammates to identify you:'}</h5>
<div className='inner__content margin--extra'>
<div className={nameDivClass}>
<div className='row'>
diff --git a/web/react/components/team_signup_welcome_page.jsx b/web/react/components/team_signup_welcome_page.jsx
index 43b7aea0e..626c6a17b 100644
--- a/web/react/components/team_signup_welcome_page.jsx
+++ b/web/react/components/team_signup_welcome_page.jsx
@@ -4,7 +4,6 @@
var Utils = require('../utils/utils.jsx');
var Client = require('../utils/client.jsx');
var BrowserStore = require('../stores/browser_store.jsx');
-import {config} from '../utils/config.js';
export default class TeamSignupWelcomePage extends React.Component {
constructor(props) {
@@ -112,7 +111,7 @@ export default class TeamSignupWelcomePage extends React.Component {
src='/static/images/logo.png'
/>
<h3 className='sub-heading'>Welcome to:</h3>
- <h1 className='margin--top-none'>{config.SiteName}</h1>
+ <h1 className='margin--top-none'>{global.window.config.SiteName}</h1>
</p>
<p className='margin--less'>Let's set up your new team</p>
<p>
diff --git a/web/react/components/team_signup_with_email.jsx b/web/react/components/team_signup_with_email.jsx
index d75736bd3..4fb1c0d01 100644
--- a/web/react/components/team_signup_with_email.jsx
+++ b/web/react/components/team_signup_with_email.jsx
@@ -3,7 +3,6 @@
const Utils = require('../utils/utils.jsx');
const Client = require('../utils/client.jsx');
-import {strings} from '../utils/config.js';
export default class EmailSignUpPage extends React.Component {
constructor() {
@@ -70,7 +69,7 @@ export default class EmailSignUpPage extends React.Component {
</button>
</div>
<div className='form-group margin--extra-2x'>
- <span><a href='/find_team'>{`Find my ${strings.Team}`}</a></span>
+ <span><a href='/find_team'>{`Find my team`}</a></span>
</div>
</form>
);
diff --git a/web/react/components/team_signup_with_sso.jsx b/web/react/components/team_signup_with_sso.jsx
index 521c21733..2849b4cbb 100644
--- a/web/react/components/team_signup_with_sso.jsx
+++ b/web/react/components/team_signup_with_sso.jsx
@@ -4,7 +4,6 @@
var utils = require('../utils/utils.jsx');
var client = require('../utils/client.jsx');
var Constants = require('../utils/constants.jsx');
-import {strings} from '../utils/config.js';
export default class SSOSignUpPage extends React.Component {
constructor(props) {
@@ -84,7 +83,7 @@ export default class SSOSignUpPage extends React.Component {
disabled={disabled}
>
<span className='icon'/>
- <span>Create {strings.Team} with GitLab Account</span>
+ <span>Create team with GitLab Account</span>
</a>
);
}
@@ -111,7 +110,7 @@ export default class SSOSignUpPage extends React.Component {
{serverError}
</div>
<div className='form-group margin--extra-2x'>
- <span><a href='/find_team'>{'Find my ' + strings.Team}</a></span>
+ <span><a href='/find_team'>{'Find my team'}</a></span>
</div>
</form>
);
diff --git a/web/react/components/user_profile.jsx b/web/react/components/user_profile.jsx
index 739084053..ad94df288 100644
--- a/web/react/components/user_profile.jsx
+++ b/web/react/components/user_profile.jsx
@@ -3,7 +3,6 @@
var Utils = require('../utils/utils.jsx');
var UserStore = require('../stores/user_store.jsx');
-import {config} from '../utils/config.js';
var id = 0;
@@ -58,7 +57,7 @@ export default class UserProfile extends React.Component {
}
var dataContent = '<img class="user-popover__image" src="/api/v1/users/' + this.state.profile.id + '/image?time=' + this.state.profile.update_at + '" height="128" width="128" />';
- if (!config.ShowEmail) {
+ if (!global.window.config.ShowEmail) {
dataContent += '<div class="text-nowrap">Email not shared</div>';
} else {
dataContent += '<div data-toggle="tooltip" title="' + this.state.profile.email + '"><a href="mailto:' + this.state.profile.email + '" class="text-nowrap text-lowercase user-popover__email">' + this.state.profile.email + '</a></div>';
diff --git a/web/react/components/user_settings_appearance.jsx b/web/react/components/user_settings_appearance.jsx
index 3afdd7349..3df013d03 100644
--- a/web/react/components/user_settings_appearance.jsx
+++ b/web/react/components/user_settings_appearance.jsx
@@ -6,7 +6,8 @@ var SettingItemMin = require('./setting_item_min.jsx');
var SettingItemMax = require('./setting_item_max.jsx');
var Client = require('../utils/client.jsx');
var Utils = require('../utils/utils.jsx');
-import {config} from '../utils/config.js';
+
+var ThemeColors = ['#2389d7', '#008a17', '#dc4fad', '#ac193d', '#0072c6', '#d24726', '#ff8f32', '#82ba00', '#03b3b2', '#008299', '#4617b4', '#8c0095', '#004b8b', '#004b8b', '#570000', '#380000', '#585858', '#000000'];
export default class UserSettingsAppearance extends React.Component {
constructor(props) {
@@ -21,8 +22,8 @@ export default class UserSettingsAppearance extends React.Component {
getStateFromStores() {
var user = UserStore.getCurrentUser();
var theme = '#2389d7';
- if (config.ThemeColors != null) {
- theme = config.ThemeColors[0];
+ if (ThemeColors != null) {
+ theme = ThemeColors[0];
}
if (user.props && user.props.theme) {
theme = user.props.theme;
@@ -83,18 +84,18 @@ export default class UserSettingsAppearance extends React.Component {
var themeSection;
var self = this;
- if (config.ThemeColors != null) {
+ if (ThemeColors != null) {
if (this.props.activeSection === 'theme') {
var themeButtons = [];
- for (var i = 0; i < config.ThemeColors.length; i++) {
+ for (var i = 0; i < ThemeColors.length; i++) {
themeButtons.push(
<button
- key={config.ThemeColors[i] + 'key' + i}
- ref={config.ThemeColors[i]}
+ key={ThemeColors[i] + 'key' + i}
+ ref={ThemeColors[i]}
type='button'
className='btn btn-lg color-btn'
- style={{backgroundColor: config.ThemeColors[i]}}
+ style={{backgroundColor: ThemeColors[i]}}
onClick={this.updateTheme}
/>
);
diff --git a/web/react/components/user_settings_notifications.jsx b/web/react/components/user_settings_notifications.jsx
index 33db1a332..dadbb669b 100644
--- a/web/react/components/user_settings_notifications.jsx
+++ b/web/react/components/user_settings_notifications.jsx
@@ -8,7 +8,6 @@ var client = require('../utils/client.jsx');
var AsyncClient = require('../utils/async_client.jsx');
var utils = require('../utils/utils.jsx');
var assign = require('object-assign');
-import {config} from '../utils/config.js';
function getNotificationsStateFromStores() {
var user = UserStore.getCurrentUser();
@@ -415,7 +414,7 @@ export default class NotificationsTab extends React.Component {
</label>
<br/>
</div>
- <div><br/>{'Email notifications are sent for mentions and private messages after you have been away from ' + config.SiteName + ' for 5 minutes.'}</div>
+ <div><br/>{'Email notifications are sent for mentions and private messages after you have been away from ' + global.window.config.SiteName + ' for 5 minutes.'}</div>
</div>
);
diff --git a/web/react/components/view_image.jsx b/web/react/components/view_image.jsx
index 8d3495e3b..f7c980396 100644
--- a/web/react/components/view_image.jsx
+++ b/web/react/components/view_image.jsx
@@ -3,7 +3,6 @@
var Client = require('../utils/client.jsx');
var Utils = require('../utils/utils.jsx');
-import {config} from '../utils/config.js';
export default class ViewImageModal extends React.Component {
constructor(props) {
@@ -301,7 +300,7 @@ export default class ViewImageModal extends React.Component {
}
var publicLink = '';
- if (config.AllowPublicLink) {
+ if (global.window.config.AllowPublicLink) {
publicLink = (
<div>
<a