Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Play button
@Composable
fun PlayTrailer(
modifier: Modifier = Modifier,
openGameTrailer: () -> Unit
) {
Box(modifier = modifier) {
IconButton(onClick = openGameTrailer) {
Image(
modifier =
Modifier.width(50.dp)
.height(50.dp)
.align(Alignment.Center)
.graphicsLayer {
shadowElevation = 20.dp.toPx()
shape =
RoundedCornerShape(15.dp)
clip = true
}
.background(Color(0xFFF50057)),
painter =
painterResource(
id = R.drawable.ic_play
),
contentDescription = "Play Trailer"
)
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment