Use modifier from parameter in UnittoListItem with switch

This commit is contained in:
Sad Ellie 2023-09-26 13:53:53 +03:00
parent dc2e4af77b
commit 4cfd876bfd

View File

@ -126,9 +126,8 @@ fun UnittoListItem(
supportingText: String? = null, supportingText: String? = null,
switchState: Boolean, switchState: Boolean,
onSwitchChange: (Boolean) -> Unit onSwitchChange: (Boolean) -> Unit
) { ) = UnittoListItem(
UnittoListItem( modifier = modifier
modifier = Modifier
.clickable( .clickable(
interactionSource = remember { MutableInteractionSource() }, interactionSource = remember { MutableInteractionSource() },
indication = rememberRipple(), indication = rememberRipple(),
@ -144,8 +143,7 @@ fun UnittoListItem(
onCheckedChange = { onSwitchChange(it) } onCheckedChange = { onSwitchChange(it) }
) )
} }
) )
}
@Composable @Composable
private fun ProvideTextStyle( private fun ProvideTextStyle(