-
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
Remove usage of select editor from the block editor module #16184
Remove usage of select editor from the block editor module #16184
Conversation
@@ -102,6 +109,7 @@ class EditorProvider extends Component { | |||
__experimentalReusableBlocks: reusableBlocks, | |||
__experimentalMediaUpload: hasUploadPermissions ? mediaUpload : undefined, | |||
__experimentalFetchLinkSuggestions: fetchLinkSuggestions, | |||
__experimentalCanUserUseUnfilteredHTML: canUserUseUnfilteredHTML, |
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.
Any reason you think this shhould be experimental?
Also these settings are documented in the defaults.js
file of the block-editor package in addition to providing the default value.
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.
Hi @youknowriad the default.js file was updated, nice catch.
The setting was only marked as experimental because lately all new additions were kept experimental for one version so I followed the same logic, but I can change it.
8c41ea2
to
5223795
Compare
5223795
to
16c677a
Compare
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.
Nice! Tested iframe pasting and it still works. :)
Description
The block editor performed a select to the core/editor store, this causes problems when the editor store is not available e.g. in the widget screen after we merge #16160.
This PR refactors to code to use a block editor setting instead of the editor store.
How has this been tested?
With an admin rule, I pasted the following in a paragraph:
<iframe src="httt://www.wordpress.org/" />
. I verified an HTML block with the iframe was created.With a contributor rule I pasted the same code I verified an HTML block with the iframe was not created.