Updating client dependencies. Switching to yarn. (#6433)
* Updating client dependancies. Switching to using yarn. * Updating React * Moving pure components to using function syntax (performance gains with newer react version) * Updating client dependancies. * Ignore .yarninstall * Enabling pre-lockfile because it's the entire point of using yarn. * Removing old webpack config * Moving to new prop-types * Fixing ESLint Errors * Updating jest snapshots. * Cleaning up package.json
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
63e599c43b
Коммит
2bbedd9def
@@ -1,3 +1,5 @@
|
||||
import PropTypes from 'prop-types';
|
||||
|
||||
// Copyright (c) 2016-present Mattermost, Inc. All Rights Reserved.
|
||||
// See License.txt for license information.
|
||||
|
||||
@@ -67,35 +69,33 @@ const WEBSERVER_MODE_HELP_TEXT = (
|
||||
</div>
|
||||
);
|
||||
|
||||
export default class WebserverModeDropdownSetting extends React.Component {
|
||||
render() {
|
||||
return (
|
||||
<DropdownSetting
|
||||
id='webserverMode'
|
||||
values={[
|
||||
{value: 'gzip', text: Utils.localizeMessage('admin.webserverModeGzip', 'gzip')},
|
||||
{value: 'uncompressed', text: Utils.localizeMessage('admin.webserverModeUncompressed', 'Uncompressed')},
|
||||
{value: 'disabled', text: Utils.localizeMessage('admin.webserverModeDisabled', 'Disabled')}
|
||||
]}
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='admin.webserverModeTitle'
|
||||
defaultMessage='Webserver Mode:'
|
||||
/>
|
||||
}
|
||||
value={this.props.value}
|
||||
onChange={this.props.onChange}
|
||||
disabled={this.props.disabled}
|
||||
helpText={WEBSERVER_MODE_HELP_TEXT}
|
||||
/>
|
||||
);
|
||||
}
|
||||
export default function WebserverModeDropdownSetting(props) {
|
||||
return (
|
||||
<DropdownSetting
|
||||
id='webserverMode'
|
||||
values={[
|
||||
{value: 'gzip', text: Utils.localizeMessage('admin.webserverModeGzip', 'gzip')},
|
||||
{value: 'uncompressed', text: Utils.localizeMessage('admin.webserverModeUncompressed', 'Uncompressed')},
|
||||
{value: 'disabled', text: Utils.localizeMessage('admin.webserverModeDisabled', 'Disabled')}
|
||||
]}
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='admin.webserverModeTitle'
|
||||
defaultMessage='Webserver Mode:'
|
||||
/>
|
||||
}
|
||||
value={props.value}
|
||||
onChange={props.onChange}
|
||||
disabled={props.disabled}
|
||||
helpText={WEBSERVER_MODE_HELP_TEXT}
|
||||
/>
|
||||
);
|
||||
}
|
||||
WebserverModeDropdownSetting.defaultProps = {
|
||||
};
|
||||
|
||||
WebserverModeDropdownSetting.propTypes = {
|
||||
value: React.PropTypes.string.isRequired,
|
||||
onChange: React.PropTypes.func.isRequired,
|
||||
disabled: React.PropTypes.bool.isRequired
|
||||
value: PropTypes.string.isRequired,
|
||||
onChange: PropTypes.func.isRequired,
|
||||
disabled: PropTypes.bool.isRequired
|
||||
};
|
||||
|
||||
Ссылка в новой задаче
Block a user