Tap-hold is a mechanism that lets you map a button to one function when it is clicked and another when it is held. For example you could make the middle mouse button act as middle button when it is clicked, but trigger a layer (or a modifier like Shift) when it is held.
The threshold between tap and hold is configurable (globally, not per-mapping) and is set to 200ms by default.
A mapping with the "tap" flag set can also be sticky. For example you could make one "button X->layer Y" mapping with "tap"+"sticky" flags and another "button X->layer Y" mapping with the "hold" flag. That way the layer would latch on when the button is clicked, but would only activate temporarily when it is held.