Run a callback when an element is pressed and held, with mouse or touch.
This is custom React hooks, you need to follow the Basic Rules when you use it.
Hold the button for one second.
const useLongPress = (
onLongPress: () => void,
options?: { threshold?: number },
) => {
onMouseDown: () => void
onMouseUp: () => void
onMouseLeave: () => void
onTouchStart: () => void
onTouchEnd: () => void
}