JedWatson / react-tappable

Tappable component for React
http://jedwatson.github.io/react-tappable/
MIT License
863 stars 90 forks source link

Elements sitting within and above the tappable area need to override (nested Tappable) #128

Open ericjames opened 5 years ago

ericjames commented 5 years ago

An element that sits inside a tappable area with a higher zindex should take precedence and not trigger the tappable event inside it. In my case the underlying "card" layer is tappable as a whole but there is a button element that should have its own tap action.

stopPropagation doesn't seem to do anything. There really should be a "bubble" level specification.

<Tappable>
    Card layer divs tappable
    <Tappable><Button> zIndex = 100, does its own thing, Card layer ignored</Button></Tappable>
</Tappable>