SmallFloatingActionButton

fun SmallFloatingActionButton(onClick: () -> Unit, icon: SparkIcon, contentDescription: String?, modifier: Modifier = Modifier, shape: Shape = FloatingActionButtonDefaults.smallShape, containerColor: Color = FloatingActionButtonDefaults.containerColor, contentColor: Color = contentColorFor(containerColor), elevation: FloatingActionButtonElevation = FloatingActionButtonDefaults.elevation(), interactionSource: MutableInteractionSource = remember { MutableInteractionSource() })

Material Design small floating action button.

The FAB represents the most important action on a screen. It puts key actions within reach.

Small FAB image

Parameters

onClick

called when this FAB is clicked

icon

icon to show inside the FAB

contentDescription

text used by accessibility services to describe what this icon represents. This should always be provided unless this icon is used for decorative purposes, and does not represent a meaningful action that a user can take. This text should be localized, such as by using androidx.compose.ui.res.stringResource or similar

modifier

the Modifier to be applied to this FAB

shape

defines the shape of this FAB's container and shadow (when using elevation)

containerColor

the color used for the background of this FAB. Use Color.Transparent to have no color.

contentColor

the preferred color for content inside this FAB. Defaults to either the matching content color for containerColor, or to the current LocalContentColor if containerColor is not a color from the theme.

elevation

FloatingActionButtonElevation used to resolve the elevation for this FAB in different states. This controls the size of the shadow below the FAB. Additionally, when the container color is ColorScheme.surface, this controls the amount of main color applied as an overlay. See also: Surface.

interactionSource

the MutableInteractionSource representing the stream of Interactions for this FAB. You can create and pass in your own remembered instance to observe Interactions and customize the appearance / behavior of this FAB in different states.