-
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
Allow using a text label instead of an icon on overlay menu toggle button #36149
Conversation
Size Change: +457 B (0%) Total Size: 1.13 MB
ℹ️ View Unchanged
|
Are there any other blocks where the text is entered in the settings sidebar, and not edited in the block it self? |
I don't know. My initial approach was editing directly in the label, but since it's a button, clicking it toggles the menu instead of allowing you to edit the text. |
Instead of creating a new flyout component for this, because I suspect that will happen as part of #34574 or #27331, perhaps we could explore a smaller temporary solution. The entire reason for surfacing these options upon clicking a visual representation of the burger icon is both to give those options context (the burger might not be visible in the canvas), but also to manage the weight of the controls in the inspector. That's the reason for the sliding mechanism in global styles (to drill in), and the flyout pattern for ItemGroups (#35093). And so we definitely should change to use a flyout component once that lands. But in absence of building such a flyout for this, we could perhaps do a small "show/hide" trick. In this mockup, you click the gray icon card to surface controls relevant to to it: What do you think? |
0eee722
to
0ac7634
Compare
Nice work, I think we might be able to work with it. The card needs to be a bit smaller and have the right toggled state, I can probably help with that. The benefit of this preview card is that it will work whether or not you have the menu set to responsive on mobile or always. In that vein, we might want to toggle that card off, at least for now, for when you have it set to never collapse. Finally, this change doesn't preclude a future iteration where the in-canvas field becomes editable. |
0ac7634
to
0912320
Compare
I spent some time trying to figure out why e2e tests were consistently failing, and then they didn't anymore :)
I would appreciate the help! |
I'll take a stab at some polish when I get a moment!
Yes, I do think we need to do something there. In fact, since this will intentionally be a temporary step until we can have some flyout mechanism, I/we probably need to look at what this will look at for that flyout, even if we aren't implementing that bit yet, just so we know where we need to aim. I'll look at it. |
6b4ec54
to
26649f3
Compare
dbe4079
to
11962df
Compare
PR rebased and conflicts resolved 👍 |
11962df
to
114ddb1
Compare
Conflicts fixed again; this is ready for a final code review ✅. @aristath could I ask for your help with that? |
114ddb1
to
0b10669
Compare
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.
Tested on my machine and everything seems to be working as described
Nice to see this one land! |
Description
Closes #33985.
Allow replacing the toggle button for the Overlay menu with a text label.
How has this been tested?
Screenshots
Types of changes
New feature.