From 27dc6495a4e91013a3f9775de1dfb7f7ab8fff95 Mon Sep 17 00:00:00 2001 From: SergeyEzhin Date: Mon, 31 May 2021 18:08:02 +0300 Subject: [PATCH] [PE mobile] Bug 47978 --- .../mobile/lib/controller/collaboration/Comments.jsx | 12 +++++++++++- .../mobile/lib/view/collaboration/Comments.jsx | 5 +++-- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/apps/common/mobile/lib/controller/collaboration/Comments.jsx b/apps/common/mobile/lib/controller/collaboration/Comments.jsx index 1251123393..e1ebcda4be 100644 --- a/apps/common/mobile/lib/controller/collaboration/Comments.jsx +++ b/apps/common/mobile/lib/controller/collaboration/Comments.jsx @@ -558,10 +558,20 @@ class ViewCommentsController extends Component { break; } } + + showComment (comment) { + const api = Common.EditorApi.get(); + + api.asc_selectComment(comment.uid); + api.asc_showComment(comment.uid, false); + } + + render() { return( - {this.props.allComments && } + {this.props.allComments && } {this.state.isOpenViewCurComments && { } // View comments -const ViewComments = ({storeComments, storeAppOptions, onCommentMenuClick, onResolveComment}) => { +const ViewComments = ({storeComments, storeAppOptions, onCommentMenuClick, onResolveComment, showComment}) => { const { t } = useTranslation(); const _t = t('Common.Collaboration', {returnObjects: true}); const isAndroid = Device.android; @@ -657,7 +657,8 @@ const ViewComments = ({storeComments, storeAppOptions, onCommentMenuClick, onRes {sortComments.map((comment, indexComment) => { return ( - + { + !e.target.closest('.comment-menu') && !e.target.closest('.reply-menu') ? showComment(comment) : null}}>
{isAndroid &&
{comment.userInitials}
}