Skip to content

Commit 72bde31

Browse files
committed
Bug fix for: Element with role=img says it gets an acc name from alt attribute · Issue #21
1 parent 4b59f98 commit 72bde31

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

docs/Sample JavaScript Recursion Algorithm/recursion.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Distributed under the terms of the Open Source Initiative OSI - MIT License
1414
window[nameSpace] = {};
1515
nameSpace = window[nameSpace];
1616
}
17-
nameSpace.getAccNameVersion = "2.62";
17+
nameSpace.getAccNameVersion = "2.63";
1818
// AccName Computation Prototype
1919
nameSpace.getAccName = nameSpace.calcNames = function (
2020
node,
@@ -561,7 +561,8 @@ Plus roles extended for the Role Parity project.
561561
false;
562562

563563
var nAlt =
564-
rolePresentation && nTag === "img"
564+
(btnType !== "image" && nTag !== "img") ||
565+
(rolePresentation && nTag === "img")
565566
? ""
566567
: trim(node.alt || node.getAttribute("alt"));
567568

0 commit comments

Comments
 (0)