palantir/blueprint

[v5] Popover not closing when navigating lazily loaded pages via React Router

Open

#6518 opened on Nov 6, 2023

View on GitHub
 (2 comments) (3 reactions) (0 assignees)TypeScript (20,263 stars) (2,167 forks)batch import
P2Package: coreType: bughelp wanted

Description

Environment

  • Package version(s): @blueprintjs/core 5.6.0
  • Operating System: Windows 10
  • Browser name and version: Chrome 118

Code Sandbox

https://codesandbox.io/p/sandbox/blueprint5-popover-issue-9zjj9x

Steps to reproduce

  1. Use the navbar menu to navigate to "Page 2"

Actual behavior

When using React Router to navigate to a lazily loaded page, the popover menu does not close and loses interactivity.

Expected behavior

The popover menu should close after the page transition.

Possible solution

No current solution to propose. We're currently migrating our code from Blueprint v4 to v5 and noticed this issue.

Contributor guide