-
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
ToolsPanel: Ensure display of optional items when panel id is null #47864
ToolsPanel: Ensure display of optional items when panel id is null #47864
Conversation
This ensures the panel will display an optional control when its value has been updated externally to the control within the ToolsPanelItem and the panel id is null e.g. when pasting styles on multiple block selections.
Size Change: +11 B (0%) Total Size: 1.32 MB
ℹ️ View Unchanged
|
Flaky tests detected in 7272c30. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/4121797714
|
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.
This tested well for me:
✅ Tests passed
✅ Optional tools panel items displayed when styles pasted to single and multiple blocks
✅ Default items still work as expected with menu items being updated when values customised, etc.
Do we need this to be backported to 6.2 ? Feel free to remove the label, in case we don't :) |
Cherry-picked this PR to the wp/6.2 branch. |
Related:
What?
Ensures optional tools panel items are toggled on for display, even when the panel Id is
null
, e.g. when pasting styles on a multi-block selection.Why?
When you paste styles, you expect to be able to see the design tools containing the styles you are pasting.
How?
Testing Instructions
npm run test:unit:watch packages/components/src/tools-panel
Screenshots or screencast
Screen.Recording.2023-02-08.at.5.23.29.pm.mp4
Screen.Recording.2023-02-08.at.5.05.32.pm.mp4