mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
PLT-4125 Prevent typing on settings that use the regenerate button (#4016)
This commit is contained in:
@@ -37,14 +37,9 @@ export default class GeneratedSetting extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
|
||||
this.handleChange = this.handleChange.bind(this);
|
||||
this.regenerate = this.regenerate.bind(this);
|
||||
}
|
||||
|
||||
handleChange(e) {
|
||||
this.props.onChange(this.props.id, e.target.value === 'true');
|
||||
}
|
||||
|
||||
regenerate(e) {
|
||||
e.preventDefault();
|
||||
|
||||
@@ -76,8 +71,7 @@ export default class GeneratedSetting extends React.Component {
|
||||
id={this.props.id}
|
||||
placeholder={this.props.placeholder}
|
||||
value={this.props.value}
|
||||
onChange={this.handleChange}
|
||||
disabled={this.props.disabled}
|
||||
disabled={true}
|
||||
/>
|
||||
{disabledText}
|
||||
<div className='help-text'>
|
||||
|
||||
Reference in New Issue
Block a user