-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Update icons for off-canvas navigation #47337
Conversation
Size Change: -121 B (0%) Total Size: 1.33 MB
ℹ️ View Unchanged
|
Flaky tests detected in ef85348. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/3982718753
|
I dig it! Thank you! I would note, however, that IMO we don't need two icons here: The back icon and the block icon, it just adds noise. I think we can do with just the back button. It will essentially be replacing the block icon when on a subpage. Doesn't have to be part of this PR, it's some feedback I think I've left in other threads as well, but in case it's an easy fix :) |
Yes, let's follow-up with not showing the submenu block's icon when in the context of the navigation block. And just use the < icon, which takes you back to the list. |
@jasmussen Do you think all nested blocks in the off-canvas view should work this way? |
No, for the time being this should be reserved for the navigation inspector, where I imagine that the inspector itself will be animated a bit like how Global Styles animates its inspector. That makes it feel more like a single block, and conceptually I think we use that same interface for contentOnly locked blocks as well: If the interface proves itself well for those two cases, I think we could look at it again! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me 👍
if ( context === 'list-view' ) { | ||
return page; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just noting this will apply in all list views not just the Nav offcanvas. Just being sure that's your intention.
Thanks for taking care of this! |
What?
Polishes the Page List, Page List Item, and Navigation Submenu blocks icons for off-canvas navigation. The Navigation Submenu icon is only changed within the list-view context.
Closes #47283
Closes #47267
Why?
Cleaning up the off-canvas navigation icons.
Testing Instructions
Screenshot
Before:
After:
Standalone submenu block still uses its existing icon: