androidx.compose.material3

FlexibleBottomAppBarSince 1.10Experimental

Composable function

One of the bottom app bar types. It works like BottomAppBar. Only the parameters that differ are described here.

An Expressive bottom bar for actions only. It has no FAB slot; put a filled icon button in the row instead.

A flexible bottom app barExpressive theme
A flexible bottom app bar
FlexibleBottomAppBar(Modifier.width(360.dp)) {
    IconButton(onClick = {}) { Icon(Icons.Filled.Home, "Home") }
    IconButton(onClick = {}) { Icon(Icons.Filled.Search, "Search") }
    FilledIconButton(onClick = {}) { Icon(Icons.Filled.Add, "Add") }
    IconButton(onClick = {}) { Icon(Icons.Filled.Favorite, "Favorites") }
    IconButton(onClick = {}) { Icon(Icons.Filled.Person, "Profile") }
}

ParametersExperimental

@Composable
fun FlexibleBottomAppBar(
    modifier: Modifier = Modifier,
    containerColor: Color = BottomAppBarDefaults.containerColor,
    contentColor: Color = contentColorFor(containerColor),
    contentPadding: PaddingValues = BottomAppBarDefaults.FlexibleContentPadding,
    horizontalArrangement: Arrangement.Horizontal = BottomAppBarDefaults.FlexibleHorizontalArrangement,
    expandedHeight: Dp = BottomAppBarDefaults.FlexibleBottomAppBarHeight,
    windowInsets: WindowInsets = BottomAppBarDefaults.windowInsets,
    scrollBehavior: BottomAppBarScrollBehavior? = null,
    content: @Composable RowScope.() -> Unit,
)

horizontalArrangement: Arrangement.HorizontalOptional

Default: BottomAppBarDefaults.FlexibleHorizontalArrangement

How the items are spread across the bar.

expandedHeight: DpOptional

Default: BottomAppBarDefaults.FlexibleBottomAppBarHeight

The height of the bar.

Defaults that differ from BottomAppBar:

Same as in BottomAppBar: modifier, containerColor, contentColor, contentPadding, windowInsets, scrollBehavior, content.

Bottom app bar types

See also