NavigationDrawerItemDefaults


Defaults used in NavigationDrawerItem.

Summary

Public functions

NavigationDrawerItemColors
@Composable
colors(
    selectedContainerColor: Color,
    unselectedContainerColor: Color,
    selectedIconColor: Color,
    unselectedIconColor: Color,
    selectedTextColor: Color,
    unselectedTextColor: Color,
    selectedBadgeColor: Color,
    unselectedBadgeColor: Color
)

Creates a NavigationDrawerItemColors with the provided colors according to the Material specification.

Cmn

Public properties

PaddingValues

Default external padding for a NavigationDrawerItem according to the Material specification.

Cmn

Public functions

colors

@Composable
fun colors(
    selectedContainerColor: Color = NavigationDrawerTokens.ActiveIndicatorColor.value,
    unselectedContainerColor: Color = Color.Transparent,
    selectedIconColor: Color = NavigationDrawerTokens.ActiveIconColor.value,
    unselectedIconColor: Color = NavigationDrawerTokens.InactiveIconColor.value,
    selectedTextColor: Color = NavigationDrawerTokens.ActiveLabelTextColor.value,
    unselectedTextColor: Color = NavigationDrawerTokens.InactiveLabelTextColor.value,
    selectedBadgeColor: Color = selectedTextColor,
    unselectedBadgeColor: Color = unselectedTextColor
): NavigationDrawerItemColors

Creates a NavigationDrawerItemColors with the provided colors according to the Material specification.

Parameters
selectedContainerColor: Color = NavigationDrawerTokens.ActiveIndicatorColor.value

the color to use for the background of the item when selected

unselectedContainerColor: Color = Color.Transparent

the color to use for the background of the item when unselected

selectedIconColor: Color = NavigationDrawerTokens.ActiveIconColor.value

the color to use for the icon when the item is selected.

unselectedIconColor: Color = NavigationDrawerTokens.InactiveIconColor.value

the color to use for the icon when the item is unselected.

selectedTextColor: Color = NavigationDrawerTokens.ActiveLabelTextColor.value

the color to use for the text label when the item is selected.

unselectedTextColor: Color = NavigationDrawerTokens.InactiveLabelTextColor.value

the color to use for the text label when the item is unselected.

selectedBadgeColor: Color = selectedTextColor

the color to use for the badge when the item is selected.

unselectedBadgeColor: Color = unselectedTextColor

the color to use for the badge when the item is unselected.

Public properties

ItemPadding

val ItemPaddingPaddingValues

Default external padding for a NavigationDrawerItem according to the Material specification.