dont render if reduced motion

This commit is contained in:
Hailey
2024-09-02 01:11:52 -07:00
parent eac187c4ca
commit 284d757311
2 changed files with 37 additions and 33 deletions
+2
View File
@@ -153,6 +153,7 @@ export function CountWheel({
{formattedCount} {formattedCount}
</Text> </Text>
</Animated.View> </Animated.View>
{shouldAnimate ? (
<Animated.View <Animated.View
entering={exitingAnimation} entering={exitingAnimation}
// Add 2 to the key so there are never duplicates // Add 2 to the key so there are never duplicates
@@ -170,6 +171,7 @@ export function CountWheel({
{formattedPrevCount} {formattedPrevCount}
</Text> </Text>
</Animated.View> </Animated.View>
) : null}
</View> </View>
) : null} ) : null}
</LayoutAnimationConfig> </LayoutAnimationConfig>
@@ -97,6 +97,7 @@ export function CountWheel({
{formattedCount} {formattedCount}
</Text> </Text>
</View> </View>
{shouldAnimate ? (
<View <View
style={{position: 'absolute'}} style={{position: 'absolute'}}
aria-disabled={true} aria-disabled={true}
@@ -113,6 +114,7 @@ export function CountWheel({
{formattedPrevCount} {formattedPrevCount}
</Text> </Text>
</View> </View>
) : null}
</View> </View>
) )
} }