Skip to content
Performance & Accessibility

Pointer Cancellation: What Actually Works

Designing clicks and taps so an action happens when the pointer is released, not when it is first pressed, giving people a chance to slide away and cancel.

Marcus Adeyemi Technical Director 2 min read 20 views
Pointer Cancellation: What Actually Works

The key figures

WCAG 2.5.2 Pointer Cancellation, A
for single-pointer actions, the down-event does not trigger the action, or it can be aborted or undone
Default behavior
native buttons and links activate on the up-event
Exceptions
actions where the down-event is essential, such as a piano key
Drag and drop
should allow canceling by releasing outside a target

Why this is worth getting right

People with tremors or limited dexterity often press the wrong target, and triggering on the down event gives them no way to undo, so WCAG addresses it at level A.

Do this, not that

Do

  • Use native buttons and links where possible
  • Trigger custom controls on click, not mousedown or touchstart
  • Allow undo for accidental actions
  • Let drag operations cancel when released outside targets
  • Test custom controls with deliberate slide-off presses

Don’t

  • Custom controls that fire on mousedown
  • Instant deletion on touchstart
  • Long-press actions with no cancel
  • Irreversible actions with no confirmation

When to bring in help

Our advice Bring in help when building custom interactive components, games or drag-and-drop interfaces.

Where this comes from

The figures and practices above come from the sources listed.

Working on something like this?

We take on Performance & Accessibility work for teams who want it done once, properly. Tell us what you are building and we will tell you honestly whether we are the right studio for it. Start a project.

Where to go next

Spotted something wrong? Report an error on this page. We correct on the page and say what changed.

All services

The work behind this article, and what it costs.

Marcus Adeyemi

Builds and maintains the web work. Writes about front-end architecture, performance, accessibility and the unglamorous parts of keeping a site alive.

Keep reading

More in Performance & Accessibility