Source set: Common
public object ShortNavigationBarItemDefaults
Defaults used in ShortNavigationBarItem.
Functions
colors
Source set: Common
@Composable
public fun colors(): NavigationItemColors
Creates a NavigationItemColors with the provided colors according to the Material specification.
colors
Source set: Common
@Composable
public fun colors(
selectedIconColor: Color = NavigationBarTokens.ItemActiveIconColor.value,
selectedTextColorTopIconPosition: Color =
NavigationBarTokens.ItemActiveLabelTextColor.value,
selectedTextColorStartIconPosition: Color = NavigationBarTokens.ItemActiveIconColor.value,
selectedIndicatorColor: Color = NavigationBarTokens.ItemActiveIndicatorColor.value,
unselectedIconColor: Color = NavigationBarTokens.ItemInactiveIconColor.value,
unselectedTextColor: Color = NavigationBarTokens.ItemInactiveLabelTextColor.value,
disabledIconColor: Color = unselectedIconColor.copy(alpha = DisabledAlpha),
disabledTextColor: Color = unselectedTextColor.copy(alpha = DisabledAlpha),
): NavigationItemColors
Creates a NavigationItemColors with the provided colors according to the Material specification.
Parameters
| selectedIconColor | the color to use for the icon when the item is selected. |
| selectedTextColorTopIconPosition | the color to use for the text label when the item is selected and is in the Top icon position configuration. |
| selectedTextColorStartIconPosition | the color to use for the text label when the item is selected and is in the Start icon position configuration. |
| selectedIndicatorColor | the color to use for the indicator when the item is selected. |
| unselectedIconColor | the color to use for the icon when the item is unselected. |
| unselectedTextColor | the color to use for the text label when the item is unselected. |
| disabledIconColor | the color to use for the icon when the item is disabled. |
| disabledTextColor | the color to use for the text label when the item is disabled. |
Return
the resulting NavigationItemColors used for ShortNavigationBarItem
colors
Source set: Common
@Deprecated("Maintained for binary compatibility", level = DeprecationLevel.HIDDEN)
@Composable
public fun colors(
selectedIconColor: Color = NavigationBarTokens.ItemActiveIconColor.value,
selectedTextColor: Color = NavigationBarTokens.ItemActiveLabelTextColor.value,
selectedIndicatorColor: Color = NavigationBarTokens.ItemActiveIndicatorColor.value,
unselectedIconColor: Color = NavigationBarTokens.ItemInactiveIconColor.value,
unselectedTextColor: Color = NavigationBarTokens.ItemInactiveLabelTextColor.value,
disabledIconColor: Color = unselectedIconColor.copy(alpha = DisabledAlpha),
disabledTextColor: Color = unselectedTextColor.copy(alpha = DisabledAlpha),
): NavigationItemColors