colors

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


@Composable
fun colors(containerColor: Color = WideNavigationRailDefaults.containerColor, contentColor: Color = contentColorFor(containerColor), modalContainerColor: Color = NavigationRailExpandedTokens.ModalContainerColor.value, modalScrimColor: Color = ScrimTokens.ContainerColor.value.copy(ScrimTokens.ContainerOpacity), modalContentColor: Color = contentColorFor(modalContainerColor)): WideNavigationRailColors

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

Parameters

containerColor

the color used for the background of a non-modal wide navigation rail.

contentColor

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

modalContainerColor

the color used for the background of a modal wide navigation rail.

modalScrimColor

the color used for the scrim overlay for background content of a modal wide navigation rail

modalContentColor

the preferred color for content inside a modal wide navigation rail. Defaults to either the matching content color for modalContainerColor, or to the current LocalContentColor if modalContainerColor is not a color from the theme