Repository navigation
Fix: Show creation popover on empty page links in the navigation sidebar. - #48746
Conversation
|
Size Change: +86 B (0%) Total Size: 1.34 MB
ℹ️ View Unchanged
|
|
Thanks for working on this. Before before.mp4After after.mp4The popover position feels a bit unexpected, mostly because it hides the related menu item. Is there anything we could do about that? It's especially awkward when the popover is small: It seems to be pinned to the top, left corner of the viewport rather than the menu item. Perhaps it's something for a different PR, but it's a bit strange how the empty Page Link receives the selected styling if you close the popover without choosing a page. It would be good to remove that. |
|
Flaky tests detected in 01c17e5. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/4326766623
|
|
It seems this change should also be backported in the Navigation block's list view as well? |
|
I just cherry-picked this PR to the wp/6.2 branch to get it included in the next release: 83d6dec |



This PR fixes the navigation sidebar and shows the page/custom link creation popover when the user clicks on an empty custom/page link block on the navigation sidebar.
Testing
Add a page link block on the navigation sidebar.
Leave it empty and close the popover.
Click on the block and verify the popover appears again.
Repeat the steps for the custom link case.