How can I reduce the padding inside the button? I want the text to be closer to the edge of the button
Button(
onClick = {},
modifier = Modifier.padding(0.dp),
shape = RoundedCornerShape(30.dp),
border = BorderStroke(1.dp, Color(0xFFC4C4C4)),
colors = ButtonDefaults.buttonColors(
contentColor = MaterialTheme.colors.onBackground,
backgroundColor = MaterialTheme.colors.onBackground
)
) {
Text(
text = "lorem ipsu",
fontSize = 13.sp,
textAlign = TextAlign.Center,
modifier = Modifier.padding(start = 1.dp, end = 1.dp)
)
}

You can use contentPadding
Button(
onClick = {},
contentPadding = PaddingValues(
start = 4.dp,
top = 4.dp,
end = 4.dp,
bottom = 4.dp,
)
) {
// TODO
}
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