Repository navigation
102436: Concierge - RHP closes when dismissing an attachment with Esc or expanding a chart - #102937
Conversation
… or expanding a chart
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
Dropping off, not sure why it put two product review on here. 👍 |
|
@situchan all yours |
|
@situchan bump |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safaritest.mov |
|
Both fixes target the right root causes. NAB suggestions: Esc fix (SidePanelModal/index.tsx#L52): useKeyboardShortcut(
CONST.KEYBOARD_SHORTCUTS.ESCAPE,
() => {
if (!areAllModalsHidden()) {
return;
}
closeSidePanel();
},
{isActive: !isExtraLargeScreenWidth, shouldBubble: false},
);
History fix (useSyncSidePanelWithHistory/index.ts#L30): Looks good. Optional alternative: check whether the panel's entry is in history at all, like useSyncMfaModalNavigatorWithHistory. That covers any entry added after the panel's later on, but the panel would then stay open under the MFA flow instead of closing. |
Code reviewBoth fixes target the right causes. I recommend one change to the Esc fix before merge. The history fix looks correct. 1. Esc fix can still close the panel when modals are stacked (recommended change)
Example on web, below the XL breakpoint:
The menu's I agree with 2. History fix: looks good
3. Minor
I reviewed the code only. I didn't run the stacked-modal example in the app. |
|
@abbasifaizan70 wanna address this comment before we merge? #102937 (comment) |
…ertModalBecomeVisible flag
|
@situchan @luacmartins Done — the Esc handler now checks |
3d2a409
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚧 luacmartins has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/luacmartins in version: 9.5.6-0 🚀
|
|
No help site update is needed. This PR is a bug fix: the Concierge side panel now stays open when you close an attachment preview with Esc or expand a chart, which is what users already expect, and no sentence in an existing article (including Concierge Basics) describes the old behavior. |
|
🚀 Deployed to production by https://github.com/puneetlath in version: 9.5.6-6 🚀
Bundle Size Analysis (Sentry): |
Explanation of Change
Two fixes for the Side Panel when it is shown as an RHP overlay (below the extra-large breakpoint):
SidePanelModalnow disables its Escape shortcut while a modal (willAlertModalBecomeVisible) is open on top of it, so the Esc that closes the attachment preview (or expanded chart) no longer also closes the panel. An RHP beneath the panel doesn't set that flag, so Esc still closes the panel in that case.useSyncSidePanelWithHistorynow skips modal back-guard history entries (CUSTOM_HISTORY-MODAL:*) when reading the last history entry, so ashouldHandleNavigationBackmodal opened from the panel is no longer mistaken for the panel being closed. Browser Back closes the modal first, then the panel.Fixed Issues
$ #102436
PROPOSAL: #102436
Tests
Bug 1: Esc closes both the attachment preview and Concierge RHP
Bug 2: Expanding a chart closes Concierge RHP
Offline tests
Same as tests.
QA Steps
Same as tests.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Pressing the ESC button is not applicable here.
Android: mWeb Chrome
Pressing the ESC button is not applicable here.
iOS: Native
Pressing the ESC button is not applicable here.
iOS: mWeb Safari
Pressing the ESC button is not applicable here.
MacOS: Chrome / Safari
Screen.Recording.2026-10-04.at.2.15.39.PM.1.mov