Configure the order of the gesture's priority list
Is your feature request related to a problem? Please describe.
Recently, I encountered a use case where I needed the onTap to have a higher priority than onFocus. And while I was able to achieve that using theuseAnimation hook, I think it would be great if I was able to configure this somewhere.
Describe the solution you'd like
I believe, it would be great if we could pass the priorities to the MotionConfig component to override the default behavior. Maybe something like this...
const priorities = ["animate", "while-hover", "while-tap", "while-focus", "exit"]
function App() {
return (
<MotionConfig priorities={priorities} >
...
</MotionConfig>
)
}
Describe alternatives you've considered
using the useAnimation hook to manage the order myself.
We've since set whileFocus to be a lower priority so hopefully this fixes it, but I don't think we'll be making the order configurable.