1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-04 16:31:13 +00:00

optimized code style

This commit is contained in:
shanshuirenjia
2018-12-11 13:44:09 +08:00
parent a25be1ce4c
commit 1a3bd048d8
4 changed files with 21 additions and 29 deletions

View File

@@ -14,8 +14,8 @@ class NewWikiDialog extends React.Component {
super(props);
this.state = {
isExist: false,
name: "",
repoID: "",
name: '',
repoID: '',
};
this.newName = React.createRef();
}
@@ -53,7 +53,7 @@ class NewWikiDialog extends React.Component {
<ModalHeader toggle={this.toggle}>{gettext('New Wiki')}</ModalHeader>
<ModalBody>
<label className="form-label">{gettext('Name')}</label>
<Input onKeyPress={this.handleKeyPress} innerRef={input => {this.newName = input}} value={this.state.name} onChange={this.inputNewName}/>
<Input onKeyPress={this.handleKeyPress} innerRef={input => {this.newName = input;}} value={this.state.name} onChange={this.inputNewName}/>
</ModalBody>
<ModalFooter>
<Button color="secondary" onClick={this.toggle}>{gettext('Cancel')}</Button>