This PR adds VFXProps.intersection to control transition shader behavior.
These property changes how element are considered to be entered to / left from the viewport.
type VFXProps = {
/**
* Options to control transition behaviour.
* These properties work similarly to the IntersectionObsrever options.
*/
intersection?: {
/** Threshold for the element to be considered "entered" to the viewport. */
threshold?: number;
/** Margin of the viewport to be used in intersection calculcation. */
rootMargin?: RectOpts;
};
};
Changes
Added VFXProps.intersection
Added new uniform value uniform float intersection
This PR adds
VFXProps.intersection
to control transition shader behavior. These property changes how element are considered to be entered to / left from the viewport.Changes
VFXProps.intersection
uniform float intersection
focusTransition