From 35ba7422fe8f5f5c5686a57a3c200393245ab7b8 Mon Sep 17 00:00:00 2001 From: Juan Aldasoro Date: Fri, 20 Dec 2024 10:37:53 +0100 Subject: [PATCH] Respect clearable setting to display the reset button. --- .../block-editor/src/components/colors-gradients/dropdown.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/block-editor/src/components/colors-gradients/dropdown.js b/packages/block-editor/src/components/colors-gradients/dropdown.js index e60add8b706d0..a18c3ba30960e 100644 --- a/packages/block-editor/src/components/colors-gradients/dropdown.js +++ b/packages/block-editor/src/components/colors-gradients/dropdown.js @@ -84,6 +84,7 @@ const renderToggle = ( settings ) => ( { onToggle, isOpen } ) => { const { + clearable, colorValue, gradientValue, onColorChange, @@ -120,7 +121,7 @@ const renderToggle = label={ label } /> - { value && ( + { clearable && value && (