Skip to content

Instantly share code, notes, and snippets.

@zurche
Created November 11, 2023 15:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zurche/1ce15f300825bf1631bbbe8bd41ec668 to your computer and use it in GitHub Desktop.
Save zurche/1ce15f300825bf1631bbbe8bd41ec668 to your computer and use it in GitHub Desktop.
Final button
@Composable
private fun NavButton(icon: ImageVector, isSelected: Boolean = false) {
val backgroundColor = if (isSelected) LightOlive else CryptoDark800
val iconTint = if (isSelected) Color.Black else Color.White
Icon(
imageVector = icon,
contentDescription = "contentDescription",
modifier = Modifier
.size(48.dp)
.background(backgroundColor, CircleShape)
.padding(10.dp),
tint = iconTint
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment