mirror of
https://github.com/wassname/talk.git
synced 2026-08-15 12:55:10 +08:00
Add cancel button to editing CommentForm
This commit is contained in:
@@ -97,9 +97,6 @@ export class EditableCommentContent extends React.Component {
|
||||
stopEditing();
|
||||
}
|
||||
}
|
||||
stopEditing() {
|
||||
this.setState({resetCounter: this.state.resetCounter + 1});
|
||||
}
|
||||
render() {
|
||||
const originalBody = this.props.comment.body;
|
||||
const editableUntil = getEditableUntilDate(this.props.comment);
|
||||
@@ -121,6 +118,7 @@ export class EditableCommentContent extends React.Component {
|
||||
bodyPlaceholder=""
|
||||
submitText={'Save changes' /* @TODO (bengo) i18n */}
|
||||
saveButtonCStyle="green"
|
||||
cancelButtonClicked={this.props.stopEditing}
|
||||
/>
|
||||
{
|
||||
editWindowExpired
|
||||
|
||||
Reference in New Issue
Block a user