Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hasAria('disabled') throws an error #915

Open
Turbo87 opened this issue Dec 4, 2020 · 3 comments
Open

hasAria('disabled') throws an error #915

Turbo87 opened this issue Dec 4, 2020 · 3 comments
Labels

Comments

@Turbo87
Copy link
Collaborator

Turbo87 commented Dec 4, 2020

hasAria() currently delegates to hasAttribute(), but the arguments.length check in hasAttribute() does not work correctly, which makes hasAria('disabled') crash.

@Turbo87 Turbo87 added the bug label Dec 4, 2020
@buschtoens
Copy link

Also, considering that isChecked() & isNotChecked() state the following:

This also supports aria-checked="true/false".

Would it make sense to extend isDisabled() & isNotDisabled() with support for aria-disabled="true/false"?

As "just" applying aria-disabled="true/false" has no real effect without the accompanying JS / CSS — clicking an <input type="checkbox" aria-disabled="true/false"> toggles just fine — I would understand, if this addition is not desirable.

@Turbo87
Copy link
Collaborator Author

Turbo87 commented Jun 25, 2021

good question... I guess right now we're a bit inconsistent in that regard 😞

what I'm wondering is if we should have something like .isChecked({ withAriaSupport: true | false }) and then potentially also a global setting like setup(QUnit.assert, { withAriaSupport: true | false }) 🤔

buschtoens added a commit to buschtoens/qunit-dom that referenced this issue Jul 29, 2021
@buschtoens
Copy link

I've started #1194, which adds the withAriaSupport option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants