IParallaxProvide
interface
Motion & Parallax
Provide context exposed by OrigamParallax to its OrigamParallaxElement children via Vue inject. Carries reactive refs for audio data, pointer event position, movement state, easing and container shape.
TypeScript
Définition
La définition TypeScript de l'interface telle que trouvée dans le code source d'origam. Cliquez sur l'icône de copie pour copier l'extrait.
API
Propriétés
Chaque propriété déclarée par cette interface, avec son type, son caractère optionnel et sa valeur par défaut.
- audioDatarequisRef<any>
- Reactive audio analysis data (frequency/amplitude array) when the parallax is driven by audio input.
- eventDatarequisRef<TPoint>
- Reactive current pointer/mouse position as a normalised TPoint { x, y }.
- movementrequisRef<{ x: number, y: number, target?: IBox | DOMRect }>
- Reactive current movement vector plus optional target bounding box. Consumed by OrigamParallaxElement to compute transforms.
- isMovingrequisRef<boolean>
- True while a pointer/scroll movement is in progress.
- eventrequisRef<TParallaxEvent>
- The active event type (scroll | move | audio…) driving this parallax instance.
- durationrequisRef<number>
- Transition duration (ms) shared with all children for interpolation.
- easingrequisRef<string>
- CSS timing-function string shared with children for transition easing.
- shaperequisRef<IBox | null>
- Bounding box of the host parallax container, updated on resize. Null before mount.
Écosystème
Utilisé par
Composants et composables qui étendent ou consomment cette interface.
Usage
Exemples
Extraits de code prêts à coller utilisant cette interface.
Injecting the parallax context in a child component