parallax all the things in react-vr
Extends Component
Type: object
(number?)
: lower rotation degree bound
(number?)
: upper rotation degree bound
(number?)
: slop to add to wrapper via prop getter
(number?)
: initial x value in view, between 0 and 1
(number?)
: initial y value in view, between 0 and 1
(number?)
: controls "bounciness"/overshoot of the onExit animation
(number?)
: controls speed of onExit animation
(boolean?)
: flip the sign on the x rotation transform style value
(boolean?)
: flip the sign on the y rotation transform style value
(boolean?)
: only map onMove events to state when "latched"
(function?)
: Is called with the StateAndHelpers of wobbly.
(function?)
: Is called with the StateAndHelpers of wobbly.
The state of wobbly and prop getters are exposed as a parameter to the render prop.
Type: object
(function)
: prop getter - returns the props to spread into the element which controls the parallax effect by moving over it.
(function)
: prop getter - returns the x,y state in a format the transform style property will take. Spread this into the style.transform array on an "Animated" element to which a parallax effect should be added. NOTE: This element must be "Animated" like "Animated.VrButton".
(number)
: state - x state value
(number)
: state - y state value
(number)
: state - the latched state
(function)
: action - function that toggles the latched date