From 0ef77f63f6ad72a0603a370a93b75a9e6198b02b Mon Sep 17 00:00:00 2001 From: igoradamenko Date: Wed, 2 May 2018 00:14:23 +0300 Subject: [PATCH] fix triple click on 'reply' --- web/app/components/comment/comment.jsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/web/app/components/comment/comment.jsx b/web/app/components/comment/comment.jsx index 18512f68..64ce3b32 100644 --- a/web/app/components/comment/comment.jsx +++ b/web/app/components/comment/comment.jsx @@ -65,7 +65,11 @@ export default class Comment extends Component { this.setState({ isInputVisible: !isInputVisible }); if (this.props.onReplyClick) { - this.props.onReplyClick(() => this.setState({ isInputVisible: false })); + if (!isInputVisible) { + this.props.onReplyClick(() => this.setState({ isInputVisible: false })); + } else { + this.props.onReplyClick(null); + } } }