-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Navigation block: custom menu imported on a delay leading to confusing UX #48045
Comments
I just tested on a fresh WP install. The menu was imported as expected using the steps in the call for testing. On an existing install that already had menus created in the Site Editor, the custom menu was not automatically imported as expected. It was available to import manually, though. Let's leave this open for more testing and feedback. |
Any more feedback/testing results here? |
Not that I'm aware of. |
Thanks for confirming the Menu side of this works 👍
As this issue refers to Menus I think we need to close it out and open a new one specifically about Widgets. Do you agree? |
Yes, Please |
Closing this as resolved. |
While using WordPress 6.2-beta3-55428 and testing something separately, I noticed a random "Custom menu imported" notice after first landing into browse mode without any navigation fallback. Happy to share the full video if it's helpful (3-4 minutes) but here's the part where suddenly I am using the Browse Mode navigation section to edit a different template and I get a notice that confuses me: custom.menu.import.movGoing to reopen this. I'm not clear on replication steps but I did do this:
|
@getdave can you look into this? |
I think it said "Classic menu imported". I'll take a look. |
@annezazu I tried to replicate this with WordPress To replicate what you have in your video the steps are:
Having discussed with @scruffian and others I believe this behaviour is expected. What's slightly unusual is that the notice doesn't appear until you are within the editor canvas. I think that's standard as we don't have a model for displaying notices outside of that right now so when notices are dispatched they are only displayed within the editor canvas. I believe what is happening is:
You'll notice that the items in the Navigation Browser mode are the same as those in the canvas. Those items in turn will correspond with any Classic Menu you have on your site. So I believe this is all expected.
No menu will display there until a menu is available. It won't be available until the import is complete. It's a limitation of requiring a network request to determine the fallback. In the future (6.3???) we may be able to solve this by always having a Navigation post created server side. |
Ah let me clarify. The "Classic menu imported" happens on a delay. I can share the full video with you to show more of what I mean. Essentially, you have classic menus in place, open the site editor, and the navigation block doesn't use any fallback. From there, randomly while editing a different template after creating a new menu, I get a notice of the import. Edit to add:
This might be the root problem 😅 I'd like to leave this issue open in any case but understand if we can't make progress for 6.2. |
If it's possible to isolate the exact steps I'd need to take to replicate this issue then we can take a look. I'm finding it a little hard to follow even with the updated description. Sorry! |
I basically think the issue is the delay in the import since a request is made server side. This delay is causing a strange UX -- you open the site editor to see no menu set then, some time later, it suddenly gives a notice of "classic menu imported". Part of why this has been so hard to replicate is that request can take different amounts of time! So sometimes it would happen while editing another template and sometimes it would happen in the same template itself and sometimes I couldn't replicate at all. Does that make more sense? I'm not quite sure what to do here to solve as the delay in the fallback is pretty confusing. |
Hi, |
@annezazu I'm working on a solution over here whereby determining the correct "fallback" and converting that into a Navigation Menu (i.e. More eyes on that PR and testing would really help. I'm currently seeking input from folks experienced with the REST API to confidence check the approach I'm suggesting. |
@spacedmonkey might you be able to take a look at the above? You come to mind when it comes to performance and REST API : ) |
I think the new endpoint in #48698 solved this issue so I'll close it hoping it won't reappear. |
As part of the twentieth call for testing for the FSE Outreach Program, a few folks noted that their custom menu from a classic theme wasn't properly used when first loading the Site Editor until the editor was refreshed in some way.
I'm afraid I do not have replication steps beyond following the steps in the call for testing:
Opening this in case others can help test and replicate since it does seem odd that a few folks could replicate this. I tried to find any related issues but couldn't identify any recently closed ones or opened ones for the navigation block. cc @getdave for the nav block side and @ironprogrammer for testing.
Of note, this call for testing was using Gutenberg 15.0 and it was the likely version when this bug was found. I cannot replicate it using Chrome, MacOS, and the steps above.
The text was updated successfully, but these errors were encountered: