I'm sure this is not the answer you want to hear, but there are THREE behaviors that should be implemented. When a user's
touchstart occurs outside the slider area, the default behavior should occur (either scrolling or a link click ect.), but when the
touchstart is inside the slider area one of three things needs to happen:
touchmoves to the slider, and only slide.
touchmoves to scrolling, and only scroll
- Allow both scrolling and sliding simultaneously.
Which one you pick is based on thresholds and requires some tuning. I will give an example of what has worked for me:
Here the center of the circle is
touchstart. As the finger moves away from the center if it falls within the 'green' area (2) lock to scroll. If the
touchmove falls into the 'orange' area (1) slide only. If neither, 'blue', then (3) do both.
The idea here is to attempt to make the behavior reflect user intent. I encourage you to experiment with the threshold of degrees, as well as how far the
touchmove must fall from
touchstart before you measure angle ( I use 10px ).
The idea here is to never let a touch fail. No matter where the users touches the display, the expected interaction should take place. Choosing any specific behavior to always occur, with the foreknowledge that the user may expect a different behavior is bad UX. We should always attempt to have our applications behave as expected, even if the user does the 'wrong' thing.