Start native apps faster with the Composables CLI ->
Object

ToggleFloatingActionButtonDefaults

Contains the default values used by ToggleFloatingActionButton

Source set: Common
public object ToggleFloatingActionButtonDefaults

Contains the default values used by ToggleFloatingActionButton

Functions

containerColor

Source set: Common
@Composable
    public fun containerColor(
        initialColor: Color = MaterialTheme.colorScheme.primaryContainer,
        finalColor: Color = MaterialTheme.colorScheme.primary,
    ): (Float) -> Color

containerSize

Source set: Common
public fun containerSize(initialSize: Dp, finalSize: Dp = FabFinalSize): (Float) -> Dp

containerSize

Source set: Common
public fun containerSize(): (Float) -> Dp

containerSizeMedium

Source set: Common
public fun containerSizeMedium(): (Float) -> Dp

containerSizeLarge

Source set: Common
public fun containerSizeLarge(): (Float) -> Dp

containerCornerRadius

Source set: Common
public fun containerCornerRadius(
        initialSize: Dp,
        finalSize: Dp = FabFinalCornerRadius,
    ): (Float) -> Dp

containerCornerRadius

Source set: Common
public fun containerCornerRadius(): (Float) -> Dp

containerCornerRadiusMedium

Source set: Common
public fun containerCornerRadiusMedium(): (Float) -> Dp

containerCornerRadiusLarge

Source set: Common
public fun containerCornerRadiusLarge(): (Float) -> Dp

iconColor

Source set: Common
@Composable
    public fun iconColor(
        initialColor: Color = MaterialTheme.colorScheme.onPrimaryContainer,
        finalColor: Color = MaterialTheme.colorScheme.onPrimary,
    ): (Float) -> Color

iconSize

Source set: Common
public fun iconSize(initialSize: Dp, finalSize: Dp = FabFinalIconSize): (Float) -> Dp

iconSize

Source set: Common
public fun iconSize(): (Float) -> Dp

iconSizeMedium

Source set: Common
public fun iconSizeMedium(): (Float) -> Dp

iconSizeLarge

Source set: Common
public fun iconSizeLarge(): (Float) -> Dp

animateIcon

Source set: Common
@Composable
    public fun Modifier.animateIcon(
        checkedProgress: () -> Float,
        color: (Float) -> Color = iconColor(),
        size: (Float) -> Dp = iconSize(),
    ): Modifier

Modifier for animating the color and size of an icon within ToggleFloatingActionButton based on a progress value.

Parameters

checkedProgress callback that provides the progress value for the icon animation
color the color of the icon, based on the checked progress value from 0-1
size the size of the icon, based on the checked progress value from 0-1