From 8ba6b11fba4e12bec3ad6174886fbcc8a97a0094 Mon Sep 17 00:00:00 2001 From: Aki Hamano <54422211+t-hamano@users.noreply.github.com> Date: Fri, 23 Aug 2024 13:02:37 +0900 Subject: [PATCH] Template Part: Hide Advanced panel for non-admin users (#64721) * Template Part: Hide Advanced panel for non-admin users * Restore original conditional statement Co-authored-by: t-hamano Co-authored-by: Mamaduka --- .../template-part/edit/advanced-controls.js | 1 - .../src/template-part/edit/index.js | 22 ++++++++++--------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/packages/block-library/src/template-part/edit/advanced-controls.js b/packages/block-library/src/template-part/edit/advanced-controls.js index 0a2b8bebbf4fc..3c319a7ec0fe7 100644 --- a/packages/block-library/src/template-part/edit/advanced-controls.js +++ b/packages/block-library/src/template-part/edit/advanced-controls.js @@ -82,7 +82,6 @@ export function TemplatePartAdvancedControls( { } } onFocus={ ( event ) => event.target.select() } /> - ) } - - - + { canUserEdit && ( + + + + ) } { isPlaceholder && (