From e141888b36299c8d7f3e032a345ffb10aab69b6b Mon Sep 17 00:00:00 2001 From: Nik Tsekouras Date: Tue, 11 May 2021 12:10:25 +0300 Subject: [PATCH] [Block Library - Post Featured Image]: Fix uneditable placeholder when outside of a post context (#31663) --- packages/block-library/src/post-featured-image/edit.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/block-library/src/post-featured-image/edit.js b/packages/block-library/src/post-featured-image/edit.js index 8dc69972af834d..3acbef27762738 100644 --- a/packages/block-library/src/post-featured-image/edit.js +++ b/packages/block-library/src/post-featured-image/edit.js @@ -120,8 +120,9 @@ function PostFeaturedImageDisplay( { const PostFeaturedImageWithNotices = withNotices( PostFeaturedImageDisplay ); export default function PostFeaturedImageEdit( props ) { + const blockProps = useBlockProps(); if ( ! props.context?.postId ) { - return placeholderChip; + return
{ placeholderChip }
; } return ; }