Skip to content

Allow extenders to remove additional format types.#204

Open
dd32 wants to merge 1 commit intoAutomattic:trunkfrom
dd32:add/unregisterFormatTypes
Open

Allow extenders to remove additional format types.#204
dd32 wants to merge 1 commit intoAutomattic:trunkfrom
dd32:add/unregisterFormatTypes

Conversation

@dd32
Copy link
Member

@dd32 dd32 commented Apr 18, 2024

Instead of rolling our own plugin to extend the editor, it would be useful if the list of unsupported format types was defined through the PHP Configuration of Blocks Everywhere.

For example; See https://meta.trac.wordpress.org/changeset/13561 for how this PR is being used currently.

bazza pushed a commit to WordPress/wordpress.org that referenced this pull request Apr 18, 2024
@dd32
Copy link
Member Author

dd32 commented Apr 18, 2024

An alternative would be to expose the allowedFormats option somewhere I guess too.

Comment on lines +334 to +337
'unregisterFormatType' => [
'core/text-color',
'core/image',
],
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Open to better names for this option too, I just named it the same as the G function it was calling, there's probably a better naming format..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant