@Composable
fun LoginMethod(icon: Icon, text: String) {
Row(
modifier = Modifier
.padding(8.dp)
.shadow(
elevation = 6.dp,
shape = RoundedCornerShape(6.dp)
)
) {
Image(imageVector = icon, contentDescription ="")
Spacer(modifier = Modifier.height(4.dp))
Text(text = text)
}
}
You can use something like:
@Composable
fun LoginMethod(icon: ImageVector, text : String) {
/* your code */
}
and then call it with:
LoginMethod( Icons.Filled.Add, "title" )
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With