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

Should the button to open the dialog have aria-haspopup="dialog" #1383

Open
DavidMacDonald opened this issue Apr 18, 2020 · 4 comments
Open

Comments

@DavidMacDonald
Copy link

https://www.w3.org/TR/wai-aria-1.2/#aria-haspopup

https://www.w3.org/TR/wai-aria-practices-1.1/examples/dialog-modal/dialog.html

@sinabahram
Copy link

Technically ,maybe, but practically speaking, 100% not. This reads terribly in screen readers, announcing menu semantics which are completely nonsensical. In Jaws, it forces forms mode and it announces the button as a menu. In NVDA, it doesn't force insert mode, but instead it announces both menu and submenu semantics. It's 100% useless, full stop. I advise any /all developers never to use aria-haspopup="dialog". I have no clue why this is implemented so badly by screen readers.

@JAWS-test
Copy link

JAWS-test commented Apr 19, 2020

In my opinion, the wrong output of aria-haspopup for buttons is not a problem of screenreaders, but of the specification that dictates this wrong output: w3c/core-aam#51

One solution would be to use a link (with aria-haspopup=dialog) to open the dialog instead of a button.

However, there are already issues for the screen readers, e.g. FreedomScientific/standards-support#82, FreedomScientific/standards-support#32, nvaccess/nvda#7836, nvaccess/nvda#9096

For a discussion of the problems with aria-haspopup=dialog see w3c/aria#1024 (comment)

@sinabahram
Copy link

sinabahram commented Apr 19, 2020 via email

@Adriani90
Copy link

Actually aria haspopup="dialog" is very useful, especially when you work together with sighted people. at least I know that something will be opened which takes part of the screen surface. In case of non modal dialogs, the focus is not redirected to the dialogs, so at least the haspopup="dialog" gives me as a screen reader user the idea of what happens on the screen.

Note that NVDA can now report this properly, you can test with the last alpha in NVDA which can be downloaded here:
https://www.nvaccess.org/files/nvda/snapshots/

So from my perspective as a blind user, it totally makes sense to set this property on what ever element that opens a dialog.

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

No branches or pull requests

4 participants