I'm writing a Framer.js function to simulate the 'splash' effect when you tap a button or a layer, as per Google Material Design.
It looks something like this
tapSplash = (tapX,tapY) ->
tapSplashLayer = new layer
backgroundColor: "#ffffff"
opacity: 0.2
width: 500, height: 1500
borderRadius: 1500
midX: tapX
midY: tapY
After this, I have some code to run the animation.
My question is, how do I get the tapX and tapY coordinates? It is not good enough to use the midpoint of the layer that has been clicked/tapped - I want the animation to originate from the exact point the user tapped on