IParallaxProps
interface
Motion & Parallax
Full props contract for <OrigamParallax>. Extends common component, color, spacing, border, dimension and audio contracts, plus parallax-specific controls for easing, speed, direction, event type and threshold.
TypeScript
Definition
The TypeScript interface definition as found in the origam source. Click the copy icon to copy the snippet.
Inheritance
Extends
Parent interfaces this one inherits from. Their properties are available on every consumer of this interface.
API
Properties
Every property declared by this interface, with its type, optionality and default.
- animationDurationnumber
- Deprecated — use `duration` instead. Kept as a silent alias for backwards compat; a one-shot console warning is emitted when used.
- easingTParallaxEasing | string
- Easing curve. Accepts a TParallaxEasing keyword (linear | ease-out | spring) or any raw CSS timing-function string.
- perspectivenumber
- CSS perspective depth (px) applied to the parallax container for 3D transform effects.
- eventTParallaxEvent
- Event type that drives the parallax — scroll, move (mouse), or similar. Controls which input is read.
- activeboolean
- Freezes the mouse-driven mode when false. Distinct from `disabled` which stops all effects.
- durationnumber
- Transition duration (ms) for the parallax interpolation. Replaces the deprecated `animationDuration`.
- directionTParallaxDirection
- Direction of the parallax effect — "vertical" (translateY), "horizontal" (translateX), or "both" (2D on mouse move).
- speednumber
- Global speed multiplier in single-layer mode. Default 0.5. Equivalent to wrapping slot in a single layer with this speed.
- disabledboolean
- Forces the parallax effect OFF (translate stays at 0). Useful for SSR, snapshot tests or prefers-reduced-motion integrations.
- thresholdnumber
- Proportion (0→1) of host visible in viewport before the effect activates. 0 = starts immediately at viewport edge, 0.3 = waits until 30% visible.
Ecosystem
Used by
Components and composables that extend or consume this interface.
Usage
Examples
Ready-to-paste code snippets using this interface.
Using IParallaxProps for a multi-layer parallax