Skip to content
Snippets Groups Projects
Commit 64d7a63f authored by Yamagishi Kazutoshi's avatar Yamagishi Kazutoshi Committed by Eugen Rochko
Browse files

Submit report using meta key (#7729)

parent c0fc4e99
Branches
Tags
No related merge requests found
......@@ -63,6 +63,12 @@ export default class ReportModal extends ImmutablePureComponent {
this.props.dispatch(submitReport());
}
handleKeyDown = e => {
if (e.keyCode === 13 && (e.ctrlKey || e.metaKey)) {
this.handleSubmit();
}
}
componentDidMount () {
this.props.dispatch(expandAccountTimeline(this.props.account.get('id'), { withReplies: true }));
}
......@@ -98,6 +104,7 @@ export default class ReportModal extends ImmutablePureComponent {
placeholder={intl.formatMessage(messages.placeholder)}
value={comment}
onChange={this.handleCommentChange}
onKeyDown={this.handleKeyDown}
disabled={isSubmitting}
/>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment