-
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
Fix property name in PluginBlockSettingsMenuItem #14741
Fix property name in PluginBlockSettingsMenuItem #14741
Conversation
It’s an upstream bug, see WordPress/gutenberg#14741
In my own testing example, I used Thanks for catching this @swissspidy I think it'll be better to fix it the other way round: rename the |
Wouldn't it be considered breaking for those which would have used |
Indeed, but I am not sure how many people that really did. I'd say most people go by the documentation, which means changing everything to I suppose we could just do |
Is it breaking if it never worked? 😆 |
Fair enough :-) I'll change it to |
Frustratingly, it's not all consistent. The I'd say as far as not creating further inconsistency, I guess the documentation may have been misled by the argument of this function? gutenberg/packages/edit-post/src/components/block-settings-menu/plugin-block-settings-menu-item.js Lines 26 to 30 in ad7d183
|
packages/edit-post/src/components/block-settings-menu/plugin-block-settings-menu-item.js
Outdated
Show resolved
Hide resolved
It'll be nice if we changed the |
Description
In #7895,
PluginBlockSettingsMenuItem
was made extensible for plugin developers.There was a slight oversight though regarding the
allowedBlockNames
prop. While the documentation was referring toallowedBlockNames
, the code was actually checking forallowedBlocks
,How has this been tested?
I extended the settings menu by using the examples from the documentation and verified that
allowedBlocks
now is properly documented as such.Screenshots
Types of changes
Bug fix (non-breaking change which fixes an issue)
Checklist: