🌈 Create new beautiful Compose Gradients with our new wesite ->
Interface

MotionScheme

A motion scheme provides all the FiniteAnimationSpecs for a MaterialTheme.

Source set: Android
public interface MotionScheme

A motion scheme provides all the FiniteAnimationSpecs for a MaterialTheme.

Motion schemes are designed to create a harmonious motion for components in the app.

There are two built-in schemes, a standard and an expressive, that can be used as-is or customized.

Functions

defaultSpatialSpec

Source set: Android
public fun <T> defaultSpatialSpec(): FiniteAnimationSpec<T>

A default spatial motion FiniteAnimationSpec.

This motion spec is designed to be applied to animations that can overshoot their targets

    limits use the effects equivalent.

  • such as shape or bounds animations. For color, alpha or other animations which have strict

T is the generic data type that will be animated by the system, as long as the appropriate TwoWayConverter for converting the data to and from an AnimationVector is supplied.

fastSpatialSpec

Source set: Android
public fun <T> fastSpatialSpec(): FiniteAnimationSpec<T>

A fast spatial motion FiniteAnimationSpec.

This motion spec is designed to be applied to animations that can overshoot their targets

    limits use the effects equivalent.

  • such as shape or bounds animations. For color, alpha or other animations which have strict

T is the generic data type that will be animated by the system, as long as the appropriate TwoWayConverter for converting the data to and from an AnimationVector is supplied.

slowSpatialSpec

Source set: Android
public fun <T> slowSpatialSpec(): FiniteAnimationSpec<T>

A slow spatial motion FiniteAnimationSpec.

This motion spec is designed to be applied to animations that can overshoot their targets

    limits use the effects equivalent.

  • such as shape or bounds animations. For color, alpha or other animations which have strict

T is the generic data type that will be animated by the system, as long as the appropriate TwoWayConverter for converting the data to and from an AnimationVector is supplied.

defaultEffectsSpec

Source set: Android
public fun <T> defaultEffectsSpec(): FiniteAnimationSpec<T>

A default effects motion FiniteAnimationSpec.

This motion spec is designed to be applied to animations that have strict limits and which shouldn't overshoot their targets - such as color or alpha animations. For shape, bounds or other animations which don't have strict limits use the 'spatial` equivalent.

T is the generic data type that will be animated by the system, as long as the appropriate TwoWayConverter for converting the data to and from an AnimationVector is supplied.

fastEffectsSpec

Source set: Android
public fun <T> fastEffectsSpec(): FiniteAnimationSpec<T>

A fast effects motion FiniteAnimationSpec.

This motion spec is designed to be applied to animations that have strict limits and which shouldn't overshoot their targets - such as color or alpha animations. For shape, bounds or other animations which don't have strict limits use the 'spatial` equivalent.

T is the generic data type that will be animated by the system, as long as the appropriate TwoWayConverter for converting the data to and from an AnimationVector is supplied.

slowEffectsSpec

Source set: Android
public fun <T> slowEffectsSpec(): FiniteAnimationSpec<T>

A slow effects motion FiniteAnimationSpec.

This motion spec is designed to be applied to animations that have strict limits and which shouldn't overshoot their targets - such as color or alpha animations. For shape, bounds or other animations which don't have strict limits use the 'spatial` equivalent.

T is the generic data type that will be animated by the system, as long as the appropriate TwoWayConverter for converting the data to and from an AnimationVector is supplied.

Members

Companion

Source set: Android
public companion object

Functions

standard

Source set: Android
public fun standard(): MotionScheme

Returns a standard Material motion scheme.

The standard scheme is Material's basic motion scheme for utilitarian UI elements and recurring interactions. It provides a linear motion feel.

expressive

Source set: Android
public fun expressive(): MotionScheme

Returns an expressive Material motion scheme.

The expressive scheme is Material's recommended motion scheme for prominent UI elements and hero interactions. It provides a visually engaging motion feel.