Skip to content

Commit

Permalink
Tweak block title comment
Browse files Browse the repository at this point in the history
  • Loading branch information
mtias committed Feb 4, 2021
1 parent 0e67f1e commit 64072fe
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions packages/block-editor/src/components/block-title/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,9 @@ export default function BlockTitle( { clientId } ) {
if ( ! name || ! blockInformation ) return null;
const blockType = getBlockType( name );
const label = reusableBlockTitle || getBlockLabel( blockType, attributes );
// Label will fallback to the title if no label is defined for the
// current label context. We do not want "Paragraph: Paragraph".
// If label is defined we prioritize it over possible possible
// block variation match title.
// Label will fallback to the title if no label is defined for the current
// label context. If the label is defined we prioritize it over possible
// possible block variation title match.
if ( label !== blockType.title ) {
return truncate( label, { length: 35 } );
}
Expand Down

0 comments on commit 64072fe

Please sign in to comment.