diff --git a/packages/block-library/src/paragraph/edit.js b/packages/block-library/src/paragraph/edit.js index b0dc5ab255af78..d32b4e8d5eca02 100644 --- a/packages/block-library/src/paragraph/edit.js +++ b/packages/block-library/src/paragraph/edit.js @@ -70,22 +70,24 @@ function DropCapControl( { clientId, attributes, setAttributes } ) { } return ( - !! dropCap } - label={ __( 'Drop cap' ) } - onDeselect={ () => setAttributes( { dropCap: undefined } ) } - resetAllFilter={ () => ( { dropCap: undefined } ) } - panelId={ clientId } - > - + !! dropCap } label={ __( 'Drop cap' ) } - checked={ !! dropCap } - onChange={ () => setAttributes( { dropCap: ! dropCap } ) } - help={ helpText } - disabled={ hasDropCapDisabled( align ) } - /> - + onDeselect={ () => setAttributes( { dropCap: undefined } ) } + resetAllFilter={ () => ( { dropCap: undefined } ) } + panelId={ clientId } + > + setAttributes( { dropCap: ! dropCap } ) } + help={ helpText } + disabled={ hasDropCapDisabled( align ) } + /> + + ); } @@ -96,6 +98,7 @@ function ParagraphBlock( { onRemove, setAttributes, clientId, + isSelected: isSingleSelected, } ) { const { align, content, direction, dropCap, placeholder } = attributes; const blockProps = useBlockProps( { @@ -131,13 +134,13 @@ function ParagraphBlock( { /> ) } - + { isSingleSelected && ( - + ) }