MCPcopy Create free account
hub / github.com/adobe/react-spectrum / onClick

Function onClick

packages/react-aria/src/dnd/useDrag.ts:403–410  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

401 }
402 },
403 onClick(e) {
404 // Handle NVDA/JAWS in browse mode, and touch screen readers. In this case, no keyboard events are fired.
405 if (isVirtualClick(e.nativeEvent) || modalityOnPointerDown.current === 'virtual') {
406 e.preventDefault();
407 e.stopPropagation();
408 startDragging(getEventTarget(e));
409 }
410 }
411 };
412 }
413

Callers 1

TransitionButtonFunction · 0.50

Calls 3

isVirtualClickFunction · 0.90
getEventTargetFunction · 0.90
startDraggingFunction · 0.70

Tested by 1

TransitionButtonFunction · 0.40