Menu Interactions

Wire mouse, wheel and touch input for react-horizontal-scrolling-menu: onWheel/onScroll are plain (api, event) => void callbacks, while ALL mouse/touch props (onMouseDown, onMouseUp, onMouseMove, onMouseLeave, onTouchStart, onTouchMove, onTouchEnd) are handler factories (api) => (event) => void. Covers mouse drag-to-scroll with the DragDealer pattern and dragging guard, onMouseLeave to stop drags, body-scroll locking, touchpad-vs-wheel detection, desktop swipe. Load when adding drag-to-scroll or custom wheel behavior, or when fixing clicks firing after drags or "Unable to preventDefault inside passive event listener".

asmyshlyaev177 506b590 12.1 KB Updated

File contents

asmyshlyaev177/react-horizontal-scrolling-menu/tree/main/skills/menu-interactions commit 506b590911

Frequently asked questions

npx skillmds@latest add asmyshlyaev177/menu-interactions