mirror of
git://develop.git.wordpress.org/
synced 2025-03-24 05:49:49 +01:00
Media: Stop arrow keys switching media if URL focused.
Keyboard handlers were prevented from navigating attachments in input fields, but the key handler excluded readonly fields, like the media URL field. This could prevent exploring the URL using the keyboard. Props jrivett, joemcgill, afercia. Fixes #43202. git-svn-id: https://develop.svn.wordpress.org/trunk@52792 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
44ec790fe6
commit
dec3f13bac
@ -251,7 +251,7 @@ EditAttachments = MediaFrame.extend(/** @lends wp.media.view.MediaFrame.EditAtta
|
||||
* focus is in a textarea or input field.
|
||||
*/
|
||||
keyEvent: function( event ) {
|
||||
if ( ( 'INPUT' === event.target.nodeName || 'TEXTAREA' === event.target.nodeName ) && ! ( event.target.readOnly || event.target.disabled ) ) {
|
||||
if ( ( 'INPUT' === event.target.nodeName || 'TEXTAREA' === event.target.nodeName ) && ! event.target.disabled ) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user