Improve API of UnreadIndicatorAtom

This commit is contained in:
Benoit Marty 2023-06-29 11:23:33 +02:00 committed by Benoit Marty
parent 349d9fbc0f
commit 8cb0e0808c
4 changed files with 4 additions and 11 deletions

View file

@ -37,12 +37,13 @@ fun UnreadIndicatorAtom(
modifier: Modifier = Modifier,
size: Dp = 12.dp,
color: Color = ElementTheme.colors.unreadIndicator,
isVisible: Boolean = true,
) {
Box(
modifier = modifier
.size(size)
.clip(CircleShape)
.background(color)
.background(if (isVisible) color else Color.Transparent)
)
}