We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
byRole
1 parent e713fee commit 49a4937Copy full SHA for 49a4937
src/queries/role.js
@@ -154,13 +154,6 @@ function queryAllByRole(
154
// don't care if aria attributes are unspecified
155
return true
156
})
157
- .filter(element => {
158
- return hidden === false
159
- ? isInaccessible(element, {
160
- isSubtreeInaccessible: cachedIsSubtreeInaccessible,
161
- }) === false
162
- : true
163
- })
164
.filter(element => {
165
if (name === undefined) {
166
// Don't care
@@ -177,6 +170,13 @@ function queryAllByRole(
177
170
text => text,
178
171
)
179
172
173
+ .filter(element => {
174
+ return hidden === false
175
+ ? isInaccessible(element, {
176
+ isSubtreeInaccessible: cachedIsSubtreeInaccessible,
+ }) === false
+ : true
+ })
180
}
181
182
function makeRoleSelector(role, exact, customNormalizer) {
0 commit comments