Tween
Props
Name | Type | Default | Description |
---|---|---|---|
animate | TweenAnimation |
| |
callbackScope | any | Scope (this) for the callbacks. The default scope is the tween. | |
completeDelay | string number object Function any[] | The time the tween will wait before the onComplete event is dispatched once it has completed, in ms. | |
delay | number Function | The number of milliseconds to delay before the tween will start. | |
duration | number | The duration of the tween in milliseconds. | |
ease | "Linear" "Stepped" "Back" "Bounce" "Circular" "Cubic" "Elastic" "Expo" "Quadratic" "Quartic" "Quintic" "Sine" ((progress: number) => number) | The easing equation to use for the tween. | |
easeParams | any[] | Optional easing parameters. | |
exit | TweenAnimation |
| |
flipX | boolean | Horizontally flip the target of the Tween when it completes (before it yoyos, if set to do so). Only works for targets that support the | |
flipY | boolean | Vertically flip the target of the Tween when it completes (before it yoyos, if set to do so). Only works for targets that support the | |
hold | number | The number of milliseconds to hold the tween for before yoyo’ing. | |
initial | TweenAnimation |
| |
loop | string number object Function any[] | The number of times the tween will repeat. (A value of 1 means the tween will play twice, as it repeated once.) The first loop starts after every property tween has completed once. | |
loopDelay | string number object Function any[] | The time the tween will pause before starting either a yoyo or returning to the start for a repeat. | |
offset | string number object Function any[] | Used when the Tween is part of a Timeline. | |
onActive | TweenOnActiveCallback | A function to call when the tween becomes active within the Tween Manager. | |
onActiveParams | any[] | Additional parameters to pass to | |
onActiveScope | any | Scope (this) for | |
onComplete | TweenOnCompleteCallback | A function to call when the tween completes. | |
onCompleteParams | any[] | Additional parameters to pass to | |
onCompleteScope | any | Scope (this) for | |
onLoop | TweenOnLoopCallback | A function to call each time the tween loops. | |
onLoopParams | any[] | Additional parameters to pass to | |
onLoopScope | any | Scope (this) for | |
onRepeat | TweenOnRepeatCallback | A function to call each time the tween repeats. Called once per property per target. | |
onRepeatParams | any[] | Additional parameters to pass to | |
onRepeatScope | any | Scope (this) for | |
onStart | TweenOnStartCallback | A function to call when the tween starts playback, after any delays have expired. | |
onStartParams | any[] | Additional parameters to pass to | |
onStartScope | any | Scope (this) for | |
onStop | TweenOnStopCallback | A function to call when the tween is stopped. | |
onStopParams | any[] | Additional parameters to pass to | |
onStopScope | any | Scope (this) for | |
onUpdate | TweenOnUpdateCallback | A function to call each time the tween steps. Called once per property per target. | |
onUpdateParams | any[] | Additional parameters to pass to | |
onUpdateScope | any | Scope (this) for | |
onYoyo | TweenOnYoyoCallback | A function to call each time the tween yoyos. Called once per property per target. | |
onYoyoParams | any[] | Additional parameters to pass to | |
onYoyoScope | any | Scope (this) for | |
repeat | number | The number of times each property tween repeats. | |
repeatDelay | number | The number of milliseconds to pause before a repeat. | |
useFrames | boolean | Use frames or milliseconds? | |
whileHover | TweenAnimation |
| |
whileTap | TweenAnimation |
| |
yoyo | boolean | Should the tween complete, then reverse the values incrementally to get back to the starting tween values? The reverse tweening will also take |