Skip to content

Commit 9063a67

Browse files
committed
Fix navigation in very very big edgecase
1 parent 181d6c7 commit 9063a67

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

src/components/SidePane/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ function SidePane() {
3030

3131
return {
3232
route: substituteRouteParameters(activeRoute, params),
33-
isInNarrowPaneModal: state?.routes?.some((r) => r.name === NAVIGATORS.RIGHT_MODAL_NAVIGATOR),
33+
isInNarrowPaneModal: state?.routes.at(-1)?.name === NAVIGATORS.RIGHT_MODAL_NAVIGATOR,
3434
};
3535
});
3636

src/hooks/useSidePane.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ function useSidePane() {
4141

4242
// The help button is hidden in production if the side pane nvp is not present or the language is unsupported.
4343
const shouldHideOnProduction = isProduction && (!sidePaneNVP || isLanguageUnsupported);
44+
4445
// The help button is also hidden if the side pane is displayed currently.
4546
const shouldHideHelpButton = shouldHideOnProduction || !isPaneHidden;
4647

0 commit comments

Comments
 (0)