Skip to content

Commit

Permalink
Speak 'Block moved up/down' after using keyboard actions to move up/down
Browse files Browse the repository at this point in the history
  • Loading branch information
n2erjo00 committed Sep 1, 2024
1 parent 843e14b commit dd47674
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/block-editor/src/components/block-tools/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,15 @@ export default function BlockTools( {
event.preventDefault();
const rootClientId = getBlockRootClientId( clientIds[ 0 ] );
moveBlocksUp( clientIds, rootClientId );
speak( __( 'Block moved up.' ) );
}
} else if ( isMatch( 'core/block-editor/move-down', event ) ) {
const clientIds = getSelectedBlockClientIds();
if ( clientIds.length ) {
event.preventDefault();
const rootClientId = getBlockRootClientId( clientIds[ 0 ] );
moveBlocksDown( clientIds, rootClientId );
speak( __( 'Block moved down.' ) );
}
} else if ( isMatch( 'core/block-editor/duplicate', event ) ) {
const clientIds = getSelectedBlockClientIds();
Expand Down

0 comments on commit dd47674

Please sign in to comment.