Package-level declarations

Types

Link copied to clipboard
private data class NavItem(val screen: Screen, val selectedIcon: Painter, val unselectedIcon: Painter? = null, val hasNews: Boolean, val size: Dp = 30.dp)

An abstraction over Screen. Specially to aid in the transformation of the icons. The Painter type is used to support Image and Vector resources (.png and .xml) and ImageVectors

Link copied to clipboard
enum Screen(@StringRes val nameRes: Int, val icon: Icon, val size: Dp = 25.dp) : Enum<Screen>

This enum defines the order in which the destinations appear. The names of the enums are also the id of the each screen

Properties

Link copied to clipboard

Builds a list of NavItems based on the Screen

Functions

Link copied to clipboard
fun BottomBar(currentScreen: Screen, onNavigateTo: (Screen) -> Unit)
Link copied to clipboard
private fun RowScope.BuildNavigationBarItem(item: NavItem, currentScreen: Screen, onClick: (item: NavItem) -> Unit)
Link copied to clipboard
private fun getBackground(currentScreen: Screen): Int
Link copied to clipboard
Link copied to clipboard
@Preview(uiMode = 32, device = "id:pixel_3")
private fun RootScreenPreview()