Only animate the like icon when from an actual toggle (#5096)

This commit is contained in:
Hailey 2024-09-03 10:55:53 -07:00 committed by GitHub
parent bd42f770b8
commit 0014d4363f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 20 additions and 9 deletions

View file

@ -71,13 +71,15 @@ const circle2Keyframe = new Keyframe({
export function AnimatedLikeIcon({
isLiked,
big,
isToggle,
}: {
isLiked: boolean
big?: boolean
isToggle: boolean
}) {
const t = useTheme()
const size = big ? 22 : 18
const shouldAnimate = !useReducedMotion()
const shouldAnimate = !useReducedMotion() && isToggle
return (
<View>