Skip to content

Commit

Permalink
Block Movers: Fix: Hide movers if there are no blocks before and after.
Browse files Browse the repository at this point in the history
  • Loading branch information
jorgefilipecosta committed Aug 1, 2018
1 parent 04961be commit 538da3d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/editor/src/components/block-mover/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export class BlockMover extends Component {
const { onMoveUp, onMoveDown, isFirst, isLast, clientIds, blockType, firstIndex, isLocked, instanceId, isHidden } = this.props;
const { isFocused } = this.state;
const blocksCount = castArray( clientIds ).length;
if ( isLocked ) {
if ( isLocked || ( isFirst && isLast ) ) {
return null;
}

Expand Down

0 comments on commit 538da3d

Please sign in to comment.