Options
All
  • Public
  • Public/Protected
  • All
Menu

Options passed to a GenericAnimation at construction time

Type parameters

  • T

Hierarchy

  • IGenericAnimationOptions

Index

Properties

Optional delay

delay: number

Time in ms before the animation is started. Animations are advanced on each frame, so this time is a minimum, not exact.

Optional duration

duration: number

Time in ms that the animation will run for. Animations are advanced on each frame, so this time is a minimum, not exact

Optional ease

ease: TEasingFn | string

An easing function used to calculate progress

from

from: T

The initial state of the animation parameter

Optional id

id: string

An identifier for the animation. Will be set to a Guid if not specified

onAnimate

onAnimate: (from: T, to: T, progress: number) => void

A function that is called each frame. Update the target of the animation here. progress is between 0 and 1.

Type declaration

    • (from: T, to: T, progress: number): void
    • Parameters

      • from: T
      • to: T
      • progress: number

      Returns void

Optional onCompleted

onCompleted: () => void

A function that is called after the animation has finished.

Type declaration

    • (): void
    • Returns void

Optional setInitialValueImmediately

setInitialValueImmediately: boolean

When true, onAnimate is called immediately with progress=0 to set the initial value

to

to: T

The final state of the animation parameter

Generated using TypeDoc