Add cancel button to editing CommentForm

This commit is contained in:
Benjamin Goering
2017-05-03 14:22:15 -07:00
parent c3f3ed8a50
commit 92fd146a8c
@@ -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