Repository navigation
Nav Block: Move color controls to support panel - #46049
Conversation
This will mean they appear under the styles tab when the block inspector tabs experiment is enabled.
|
|
|
Size Change: +76 B (0%) Total Size: 1.31 MB
ℹ️ View Unchanged
|
scruffian
left a comment
There was a problem hiding this comment.
This works and seems to be a step in the right direction.
The real issue with these color settings is that they are custom implementation rather than simply using the ones Gutenberg provides to all blocks, but this is a good first step.
Agreed, this PR only scratches the surface of addressing the Nav block's real needs. I'd expect the next step is to move the text and background colors to use the block supports. The submenu and overlay colors won't be able to be migrated to block supports if kept at the parent nav block level. With this PR, those controls will remain in the color support panel along side the text/background controls whenever they are moved. |
Related:
What?
Moves the Navigation block's ad hoc color controls into the color block supports panel.
Why?
How?
Refactors the navigation block colors away from
PanelColorSettingsto its underlyingColorGradientSettingsDropdowncomponent and then renders these to the color block support panel.Testing Instructions
Screenshots or screencast
Screen.Recording.2022-11-25.at.5.49.32.pm.mp4