Lukasz Kalnik
09/19/2024, 8:38 AMLukasz Kalnik
09/19/2024, 8:41 AMRow(
modifier = Modifier.height(Min),
verticalAlignment = Alignment.CenterVertically,
) {
OutlinedButton(
onClick = onDecreaseQuantityClicked,
modifier = Modifier.size(buttonSize),
border = BorderStroke(1.dp, MaterialTheme.colorScheme.onSurface),
shape = RoundedCornerShape(topStart = buttonCornerRadius, topEnd = 0.dp, bottomEnd = 0.dp, bottomStart = buttonCornerRadius),
contentPadding = PaddingValues(8.dp),
) {
Icon(
painter = painterResource(id = drawable.sc_ic_quantity_minus),
contentDescription = null,
tint = MaterialTheme.colorScheme.onBackground,
)
}
Box(
modifier = Modifier
.height(buttonSize)
.border(BorderStroke(1.dp, MaterialTheme.colorScheme.onSurface))
.clip(
RoundedCornerShape(
topStart = 0.dp,
topEnd = buttonCornerRadius,
bottomEnd = buttonCornerRadius,
bottomStart = 0.dp
)
)
.padding(8.dp),
contentAlignment = Alignment.Center,
) {
Text(
text = quantity.toString(),
style = MaterialTheme.typography.titleSmall,
)
}
}
Lukasz Kalnik
09/19/2024, 8:42 AMLukasz Kalnik
09/19/2024, 8:42 AMLukasz Kalnik
09/19/2024, 8:43 AMLukasz Kalnik
09/19/2024, 8:59 AM