You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The intent of this success criterion is to make it easier for users to prevent accidental or erroneous pointer input. People with various disabilities can inadvertently initiate touch or mouse events with unwanted results. Each of the following subsections roughly aligns with the bullets of this Success Criterion, and outlines a means of allowing users to cancel pointer operations.
Note: It might be related to #2700 (not 100% sure about it though)
Your environment
Software
Name(s)
Version
Radix Package(s)
@radix-ui/react-dropdown-menu
^2.0.5
React
n/a
18.2.0
Browser
Google Chrome
128.0.6613.138
Assistive tech
Node
n/a
npm/yarn
Operating System
MacOS
14.6.1
The text was updated successfully, but these errors were encountered:
bolonio
changed the title
WCAG2.2 SC 2.5.2 violation - Dropdown Menu opens on onPointerDown
[Dropdown Menu] WCAG2.2 SC 2.5.2 violation - Dropdown Menu opens on onPointerDownSep 18, 2024
Bug report
The Radix Dropdown Menu component opens on
onPointerDown
(which means as soon as a mouse navigation user presses the triggering element of the dropdown menu), but there is not available a function on the up-event, or a mechanism to abort the function before completion or to undo the function after completion. You can take a look at the Understanding SC 2.5.2: Pointer Cancellation (Level A) article for more information.Current behavior
Expected behavior
You can see the behaviour in the W3C Menu Button Pattern or in the W3C Menu Bar Pattern
or moving the mouse outside of the dropdown menu triggering and content should cancel the
onPointerDown
function.Reproducible example
Radix Dropdown Menu component
Suggested solution
Change the opening of the dropdown menu to
onPointerUp
oronClick
instead of usingonPointerDown
.Additional context
Here there are some examples of Radix components which meet the criteria, such as:
onPointerUp
)onPointerUp
)onPointerUp
)Note: It might be related to #2700 (not 100% sure about it though)
Your environment
The text was updated successfully, but these errors were encountered: