Core: Match on exact node name for :focusable and :tabbable

Fixes #10747
Ref gh-1417
(cherry picked from commit c66842b45e)
This commit is contained in:
Adam Foster 2015-01-09 16:53:30 -05:00 committed by Scott González
parent 9db405798d
commit f1345e3900

View File

@ -97,7 +97,7 @@ function focusable( element, isTabIndexNotNaN ) {
img = $( "img[usemap='#" + mapName + "']" )[ 0 ];
return !!img && visible( img );
}
return ( /input|select|textarea|button|object/.test( nodeName ) ?
return ( /^(input|select|textarea|button|object)$/.test( nodeName ) ?
!element.disabled :
"a" === nodeName ?
element.href || isTabIndexNotNaN :