From 356ce239daec7f2775ccf0ea8d708bdc7ee5e00a Mon Sep 17 00:00:00 2001 From: Bernhard Owen Josephus Date: Sat, 24 Jun 2023 14:58:16 +0800 Subject: [PATCH 1/2] fix thread parent message stays highlighted --- src/pages/home/report/ContextMenu/ContextMenuActions.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/pages/home/report/ContextMenu/ContextMenuActions.js b/src/pages/home/report/ContextMenu/ContextMenuActions.js index c39db7af6594..9cffb99588f2 100644 --- a/src/pages/home/report/ContextMenu/ContextMenuActions.js +++ b/src/pages/home/report/ContextMenu/ContextMenuActions.js @@ -117,10 +117,14 @@ export default [ shouldShow: (type, reportAction, isArchivedRoom, betas, anchor, isChronosReport, reportID) => type === CONTEXT_MENU_TYPES.REPORT_ACTION && reportAction.actionName === CONST.REPORT.ACTIONS.TYPE.ADDCOMMENT && !ReportUtils.isThreadFirstChat(reportAction, reportID), onPress: (closePopover, {reportAction, reportID}) => { - Report.navigateToAndOpenChildReport(lodashGet(reportAction, 'childReportID', '0'), reportAction, reportID); if (closePopover) { - hideContextMenu(true, ReportActionComposeFocusManager.focus); + hideContextMenu(false, () => { + Report.navigateToAndOpenChildReport(lodashGet(reportAction, 'childReportID', '0'), reportAction, reportID); + }); + return; } + + Report.navigateToAndOpenChildReport(lodashGet(reportAction, 'childReportID', '0'), reportAction, reportID); }, getDescription: () => {}, }, From 6568a55006cf270f93143765a099e8bbce67de66 Mon Sep 17 00:00:00 2001 From: Bernhard Owen Josephus Date: Tue, 27 Jun 2023 11:53:11 +0800 Subject: [PATCH 2/2] added back composer focus --- src/pages/home/report/ContextMenu/ContextMenuActions.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/pages/home/report/ContextMenu/ContextMenuActions.js b/src/pages/home/report/ContextMenu/ContextMenuActions.js index 9cffb99588f2..0a0388e414c7 100644 --- a/src/pages/home/report/ContextMenu/ContextMenuActions.js +++ b/src/pages/home/report/ContextMenu/ContextMenuActions.js @@ -119,6 +119,7 @@ export default [ onPress: (closePopover, {reportAction, reportID}) => { if (closePopover) { hideContextMenu(false, () => { + ReportActionComposeFocusManager.focus(); Report.navigateToAndOpenChildReport(lodashGet(reportAction, 'childReportID', '0'), reportAction, reportID); }); return;