2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-05-30 15:24:08 +03:00

shifting focus to parent and adding aria menuitem for dropdown

This commit is contained in:
fat
2012-12-22 13:57:57 -08:00
parent 4d195222d4
commit 2c0ed072b0
6 changed files with 73 additions and 64 deletions
+4 -1
View File
@@ -81,7 +81,10 @@
isActive = $parent.hasClass('open')
if (!isActive || (isActive && e.keyCode == 27)) return $this.click()
if (!isActive || (isActive && e.keyCode == 27)) {
if (e.which == 27) $parent.find(toggle).focus()
return $this.click()
}
$items = $('[role=menu] li:not(.divider):visible a', $parent)