Skip to content
Permalink
Browse files

Accessibility: Insert Link modal: Improve keyboard interaction.

Avoids change the selected link when using the Shift + Up/Down arrow keys
to select text in the form fields.

Props afercia.

Merges [42807] to the 5.0 branch.
Fixes #43253.

git-svn-id: https://develop.svn.wordpress.org/branches/5.0@44405 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information...
desrosj committed Jan 6, 2019
1 parent 2acbb2a commit 3f6df95e64f31fe462868d5629e935df1929f539
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/wp-includes/js/wplink.js
@@ -559,7 +559,7 @@ var wpLink;
}

// Up Arrow and Down Arrow keys.
if ( 38 !== event.keyCode && 40 !== event.keyCode ) {
if ( event.shiftKey || ( 38 !== event.keyCode && 40 !== event.keyCode ) ) {
return;
}

0 comments on commit 3f6df95

Please sign in to comment.
You can’t perform that action at this time.