From 46cd4d3225be6bea28be76270742d69ef41243f4 Mon Sep 17 00:00:00 2001 From: mkhutornyi Date: Wed, 13 Dec 2023 04:12:44 -0500 Subject: [PATCH] show 3 dots menu in expense report header --- src/components/LHNOptionsList/OptionRowLHN.js | 2 +- src/components/MoneyReportHeader.js | 28 +++++++++++++++++++ .../report/ContextMenu/ContextMenuActions.js | 6 ++-- 3 files changed, 31 insertions(+), 5 deletions(-) diff --git a/src/components/LHNOptionsList/OptionRowLHN.js b/src/components/LHNOptionsList/OptionRowLHN.js index 9b7141249180..9aee141a9cde 100644 --- a/src/components/LHNOptionsList/OptionRowLHN.js +++ b/src/components/LHNOptionsList/OptionRowLHN.js @@ -302,7 +302,7 @@ function OptionRowLHN(props) { )} - {!shouldShowGreenDotIndicator && optionItem.isPinned && ( + {!shouldShowGreenDotIndicator && !hasBrickError && optionItem.isPinned && ( { + Link.openExternalLink(CONST.NEW_ZOOM_MEETING_URL); + }), + }); + threeDotsMenuItems.push({ + icon: GoogleMeetIcon, + text: translate('videoChatButtonAndMenu.googleMeet'), + onSelected: Session.checkIfActionIsAllowed(() => { + Link.openExternalLink(CONST.NEW_GOOGLE_MEET_MEETING_URL); + }), + }); + } + return ( Navigation.goBack(ROUTES.HOME, false, true)} // Shows border if no buttons or next steps are showing below the header shouldShowBorderBottom={!(shouldShowAnyButton && isSmallScreenWidth) && !(shouldShowNextSteps && !isSmallScreenWidth)} + shouldShowThreeDotsButton + threeDotsMenuItems={threeDotsMenuItems} + threeDotsAnchorPosition={styles.threeDotsPopoverOffsetNoCloseButton(windowWidth)} > {shouldShowSettlementButton && !isSmallScreenWidth && ( diff --git a/src/pages/home/report/ContextMenu/ContextMenuActions.js b/src/pages/home/report/ContextMenu/ContextMenuActions.js index 5e6f2d46abda..6135c75b0c58 100644 --- a/src/pages/home/report/ContextMenu/ContextMenuActions.js +++ b/src/pages/home/report/ContextMenu/ContextMenuActions.js @@ -422,8 +422,7 @@ export default [ isAnonymousAction: false, textTranslateKey: 'common.pin', icon: Expensicons.Pin, - shouldShow: (type, reportAction, isArchivedRoom, betas, anchor, isChronosReport, reportID, isPinnedChat) => - type === CONTEXT_MENU_TYPES.REPORT && !isPinnedChat && !ReportUtils.isMoneyRequestReport(reportID), + shouldShow: (type, reportAction, isArchivedRoom, betas, anchor, isChronosReport, reportID, isPinnedChat) => type === CONTEXT_MENU_TYPES.REPORT && !isPinnedChat, onPress: (closePopover, {reportID}) => { Report.togglePinnedState(reportID, false); if (closePopover) { @@ -436,8 +435,7 @@ export default [ isAnonymousAction: false, textTranslateKey: 'common.unPin', icon: Expensicons.Pin, - shouldShow: (type, reportAction, isArchivedRoom, betas, anchor, isChronosReport, reportID, isPinnedChat) => - type === CONTEXT_MENU_TYPES.REPORT && isPinnedChat && !ReportUtils.isMoneyRequestReport(reportID), + shouldShow: (type, reportAction, isArchivedRoom, betas, anchor, isChronosReport, reportID, isPinnedChat) => type === CONTEXT_MENU_TYPES.REPORT && isPinnedChat, onPress: (closePopover, {reportID}) => { Report.togglePinnedState(reportID, true); if (closePopover) {