-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Description
Description
Reported by @dlh01 in https://core.trac.wordpress.org/ticket/64272
The Block Visibility plugin predates the new block hiding functionality in WordPress 6.9, as was discussed early in the new feature's development.
While the current core functionality and the plugin's functionality can complement each other, they conflict in their use of the blockVisibility block support key.
The practical consequence of this conflict that I experienced is that isn't possible to turn off core's block-hiding functionality for a particular block (via register_block_type_args) while also allowing the Block Visibility plugin to apply to that block. The blockVisibility support key will be set to true by the plugin, and so core's UI will be turned back on. As things stand, when 6.9 is released, my sites that use the plugin would begin to see two ways to hide a block that behave differently, and as far as I can tell, I can't prevent it.
It would be disappointing for this conflict to make it into core since it was an avoidable conflict and since it's not too late to fix it. The original Block Visibility plugin has 40,000 installations, which might not be large, but it's also not small. But, if that's what's going to happen, I think it would be respectful to acknowledge it.
Ping @t-hamano as the main developer for the feature.
Step-by-step reproduction instructions
- Install block visibility plugin. Apply visibility to any block.
- Check that enables core UI for all blocks.
- Both visibility rules are slightly different.
Screenshots, screen recording, code snippet
No response
Environment info
No response
Please confirm that you have searched existing issues in the repo.
- Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
- Yes
Please confirm which theme type you used for testing.
- Block
- Classic
- Hybrid (e.g. classic with theme.json)
- Not sure
Metadata
Metadata
Assignees
Labels
Type
Projects
Status