Crossfades changes in Reactions and Zaps
This commit is contained in:
@@ -726,11 +726,13 @@ fun LikeIcon(
|
||||
}
|
||||
}
|
||||
|
||||
if (reactionType != null) {
|
||||
RenderReactionType(reactionType!!, iconSize, iconFontSize)
|
||||
Crossfade(targetState = reactionType) {
|
||||
if (it != null) {
|
||||
RenderReactionType(it, iconSize, iconFontSize)
|
||||
} else {
|
||||
RenderLikeIcon(iconSize, grayTint)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
@@ -1023,7 +1025,8 @@ private fun ZapIcon(
|
||||
}
|
||||
}
|
||||
|
||||
if (wasZappedByLoggedInUser) {
|
||||
Crossfade(targetState = wasZappedByLoggedInUser) {
|
||||
if (it) {
|
||||
Icon(
|
||||
imageVector = Icons.Default.Bolt,
|
||||
contentDescription = stringResource(R.string.zaps),
|
||||
@@ -1038,6 +1041,7 @@ private fun ZapIcon(
|
||||
tint = grayTint
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
|
||||
Reference in New Issue
Block a user