Skip to content

Commit c66842b

Browse files
SlimFosterscottgonzalez
authored andcommitted
Core: Match on exact node name for :focusable and :tabbable
Fixes #10747 Ref jquerygh-1417
1 parent 4de983c commit c66842b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ui/core.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ function focusable( element, isTabIndexNotNaN ) {
103103
img = $( "img[usemap='#" + mapName + "']" )[ 0 ];
104104
return !!img && visible( img );
105105
}
106-
return ( /input|select|textarea|button|object/.test( nodeName ) ?
106+
return ( /^(input|select|textarea|button|object)$/.test( nodeName ) ?
107107
!element.disabled :
108108
"a" === nodeName ?
109109
element.href || isTabIndexNotNaN :

0 commit comments

Comments
 (0)