From 67d03d77139f0189fa3d3c3d32aa36279490b47c Mon Sep 17 00:00:00 2001 From: Shreya Agarwal <78657883+shreya0204@users.noreply.github.com> Date: Sat, 17 Aug 2024 15:52:46 +0530 Subject: [PATCH] fix: empty content sidebar panel (#64569) Co-authored-by: shreya0204 Co-authored-by: Mamaduka Co-authored-by: hanneslsm Co-authored-by: t-hamano Co-authored-by: jasmussen Co-authored-by: richtabor Co-authored-by: carolinan --- .../editor/src/components/template-content-panel/index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/editor/src/components/template-content-panel/index.js b/packages/editor/src/components/template-content-panel/index.js index af9721dfdf2b32..41e170e76daef5 100644 --- a/packages/editor/src/components/template-content-panel/index.js +++ b/packages/editor/src/components/template-content-panel/index.js @@ -59,7 +59,10 @@ export default function TemplateContentPanel() { const { enableComplementaryArea } = useDispatch( interfaceStore ); - if ( renderingMode === 'post-only' && postType !== TEMPLATE_POST_TYPE ) { + if ( + ( renderingMode === 'post-only' && postType !== TEMPLATE_POST_TYPE ) || + clientIds.length === 0 + ) { return null; }