Tuesday, June 4, 2024
104
rated 0 times [  108] [ 4]  / answers: 1 / hits: 82026  / 11 Years ago, wed, december 4, 2013, 12:00:00

I have it on good authority that aria-haspopup is appropriate for sub-menus (such as a popup context menu or sub-level menu). It's used on jQuery UI Selectmenu and also used in this great example.



What I've not been able to find out is whether aria-haspopup is applicable in the following 2 examples:




  • Informational popovers such as Bootstrap's - used for contextual information, but not containing any links

  • Pop-up browser windows - e.g. links with target=_blank



Is aria-haspopup appropriate in those situations? If not, are there ARIA attributes that should be used instead?


More From » accessibility

 Answers
15

Officially it should be used only for menus or sub-menus, from the ARIA spec 1.0:




Indicates that the element has a popup context menu or sub-level menu.




The Whatsock style guide covers this under the 'modals' section:




It might sound like a good idea to notify screen reader users that a 'Popup' is attached by adding the attribute aria-haspopup=true to the triggering element, but this is not a good idea.
... In short, don't use aria-haspopup unless you are triggering a menu.




There is some discussion about expanding the meaning in future revisions, but for the moment assume it is for menus.



I gave an answer about Bootstrap's tooltips which should help.



For pop-up browser windows, those are announced by screen readers anyway, no extra markup is needed. (NB: It helps to include a visual indicator of a new window for screen magnifier users.)


[#73913] Monday, December 2, 2013, 11 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
trentb

Total Points: 261
Total Questions: 101
Total Answers: 90

Location: French Southern and Antarctic Lands
Member since Fri, Jan 6, 2023
1 Year ago
trentb questions
Sat, Mar 27, 21, 00:00, 3 Years ago
Fri, Feb 26, 21, 00:00, 3 Years ago
Thu, Sep 24, 20, 00:00, 4 Years ago
;