From 284d75731145e0a9a0f15d521df8557453beebce Mon Sep 17 00:00:00 2001 From: Hailey Date: Mon, 2 Sep 2024 01:11:52 -0700 Subject: [PATCH] dont render if reduced motion --- src/lib/custom-animations/CountWheel.tsx | 36 +++++++++++--------- src/lib/custom-animations/CountWheel.web.tsx | 34 +++++++++--------- 2 files changed, 37 insertions(+), 33 deletions(-) diff --git a/src/lib/custom-animations/CountWheel.tsx b/src/lib/custom-animations/CountWheel.tsx index 130c71096e..10ef882e5f 100644 --- a/src/lib/custom-animations/CountWheel.tsx +++ b/src/lib/custom-animations/CountWheel.tsx @@ -153,23 +153,25 @@ export function CountWheel({ {formattedCount} - - - {formattedPrevCount} - - + {shouldAnimate ? ( + + + {formattedPrevCount} + + + ) : null} ) : null} diff --git a/src/lib/custom-animations/CountWheel.web.tsx b/src/lib/custom-animations/CountWheel.web.tsx index a00f60772d..2321ca4c4a 100644 --- a/src/lib/custom-animations/CountWheel.web.tsx +++ b/src/lib/custom-animations/CountWheel.web.tsx @@ -97,22 +97,24 @@ export function CountWheel({ {formattedCount} - - - {formattedPrevCount} - - + {shouldAnimate ? ( + + + {formattedPrevCount} + + + ) : null} ) }