Skip to content

Needs two clicks to unselect navigation link when popover is open #73178

@jeryj

Description

@jeryj

Description

Clicking to a navigation link when an unsynced link is selected will not update to the new selected block. Very likely caused by #73142 and related to #73171

Step-by-step reproduction instructions

  • Edit a single Navigation Item: Site Editor > Navigation > Edit Navigation (three dot menu)
  • Go to the Code Editor (top right Options menu > Code Editor
  • Add a broken synced navigation item by using the binding metadata with a page that does not exist (ex: 999999999):
<!-- wp:navigation-link {"label":"Broken Binding","type":"page","id":99999999,"url":"http://localhost:8888/test-renaming-page/","kind":"post-type","metadata":{"bindings":{"url":{"source":"core/post-data","args":{"field":"link"}}}}} /-->
  • Go back to the visual editor
  • You will see the Navigation Link named "Broken Binding"
  • Open the sidebar inspector
  • Click on the Broken Binding link
  • Click to a non-broken link
  • The non-broken link won't get selected. Selection stays with the broken binding link

Screenshots, screen recording, code snippet

Screen.Recording.2025-11-11.at.3.57.58.PM.mov

Environment info

No response

Please confirm that you have searched existing issues in the repo.

  • Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

  • Yes

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Block] Navigation LinkAffects the Navigation Link Block[Type] BugAn existing feature does not function as intended

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions