-
Notifications
You must be signed in to change notification settings - Fork 20
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
Post type setting field added #104
Conversation
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.
@jayedul I am seeing the following error in the Settings > Writing page, can you have a look at it?
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.
@jayedul let me know if I'm understanding this correctly. Should we limit the post types shown to only those that support the block editor? I don't think oEmbed responses, template parts, etc should be a part of this for the same reason.
If so, we can check the support using:
if ( ! use_block_editor_for_post_type( $post_type ) ) {
continue;
}
Let me know what you think.
@Sidsector9 I added the checking initially. Then removed as it doesn't exclude all the unnecessary types. You can see in the screenshot before and after adding the check. |
@jayedul So I checked, and it seems that template parts, oEmbed does have support for the block editor. |
@Sidsector9 Block editor check has been added. It can be re-reviewed though eslint test is failing here. There is no JS change in this PR, so I guess this issue is better to be fixed in a new ticket. |
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.
@jayedul I am seeing fatal error when I save settings after unchecking all the checkboxes.
@Sidsector9 back to you for review |
Description of the Change
As per current implementation, there is no way to resolve the issue other than explicitly adding
convert-to-blocks
support during custom post type registration. So, a new field added in writing setting page to enable/disableConvert to Blocks
for specific post types without editing code.Closes #57
How to test the Change
Convert to Blocks
sectionChangelog Entry
Credits
Props @jayedul
Checklist: