Repository navigation
Missing Post Type supports in Options Modal - #12394
Conversation
|
Should we also wrap the permalink section with check? It Was added in #12132. |
|
@gziolo Absolutely. Thanks for mentioning it. I've just updated the PR accordingly.
|
|
It would be nice if we didn't display the section title when there are no options underneath it. This came up in #11802 (comment) as well. |
Yes, I opened #11923 to track it. |
|
Let's tackle #11923 in a seperate PR. I don't think it's urgent. |
|
Fine with me @noisysocks, should I revert 20d1669 @gziolo ? |
Yes, I would put it in a follow-up PR so we could iterate on it 👍 |
There was a problem hiding this comment.
It's going to be a more tricky check. All those panels can be also removed programmatically :)
gziolo
left a comment
There was a problem hiding this comment.
Looks good after all changes made 👍
|
@noisysocks - do you want to perform another round of testing before we proceed? It's blocked by your review at the moment :) |
|
@gziolo: Dismissed my stale review. Am doing a support rotation this week so best not wait for me 🙂 |
|
@imath - can you rebase with |
Featured Image is not only a Theme thing, it is possible for a custom post type to declare itself without supporting the `thumbnail` feature. A custom post type can also register itself withour supporting `comments` and/or `custom-fields`. As a result the corresponding Document panels in the editor sidebar are not displayed. The Options Modal should also avoid displaying the panel checkboxes if the custom post type does not support these 3 features
As recommanded by @noisysocks : make sure the behavior about custom fields is consistent between WordPress 5.0 RC and the Gutenberg plugin
It should fix the failing test.
…alink modal options checkbox Apply @jorgefilipecosta advice.
|
@gziolo Sure, I've just rebased the PR 😉 |
|
@youknowriad sorry i’ve clicked on the resolve button before posting this comment. There’s no need to backport as it is already there these lines simply moved down a few lines. You should see the removed lines highlighted in red into the changes. |
|
And btw thanks a lot for the merge 😍 |

thumbnailfeature.commentsand/orcustom-fields.As a result the corresponding Document panels in the editor sidebar are not displayed. The Options Modal should also avoid displaying the panel checkboxes if the custom post type does not support these 3 features
Description
To fix this issue, i've wrapped featured image, comments and custom fields checkboxes into
<PostTypeSupportCheck/>componentsHow has this been tested?
I've tested the PR with the
wp_blockpost type which only supports thetitleandeditorfeatures and check everything was still behaving the right way with thepostpost type.Screenshots
Without the PR applied:
Checkboxes for featured image, comments, and custom fields are displayed although they shouldn't
With the PR applied:
The checkboxes for these 3 unsupported features are no more displayed.
Types of changes
Bug fix
Checklist: