TopAppBarScrollBehavior


A TopAppBarScrollBehavior defines how an app bar should behave when the content under it is scrolled.

Summary

Public properties

DecayAnimationSpec<Float>?

An optional DecayAnimationSpec that defined how to fling the top app bar when the user flings the app bar itself, or the content below it.

Cmn
Boolean

Indicates whether the top app bar is pinned.

Cmn
NestedScrollConnection

A NestedScrollConnection that should be attached to a Modifier.nestedScroll in order to keep track of the scroll events.

Cmn
AnimationSpec<Float>?

An optional AnimationSpec that defines how the top app bar snaps to either fully collapsed or fully extended state when a fling or a drag scrolled it into an intermediate position.

Cmn
TopAppBarState

A TopAppBarState that is attached to this behavior and is read and updated when scrolling happens.

Cmn

Public properties

flingAnimationSpec

val flingAnimationSpecDecayAnimationSpec<Float>?

An optional DecayAnimationSpec that defined how to fling the top app bar when the user flings the app bar itself, or the content below it.

isPinned

val isPinnedBoolean

Indicates whether the top app bar is pinned.

A pinned app bar will stay fixed in place when content is scrolled and will not react to any drag gestures.

nestedScrollConnection

val nestedScrollConnectionNestedScrollConnection

A NestedScrollConnection that should be attached to a Modifier.nestedScroll in order to keep track of the scroll events.

snapAnimationSpec

val snapAnimationSpecAnimationSpec<Float>?

An optional AnimationSpec that defines how the top app bar snaps to either fully collapsed or fully extended state when a fling or a drag scrolled it into an intermediate position.

state

val stateTopAppBarState

A TopAppBarState that is attached to this behavior and is read and updated when scrolling happens.