From 6548346dca9392ea1ffe447f061c8c3d03a72ed3 Mon Sep 17 00:00:00 2001 From: Noel De Martin Date: Thu, 1 Feb 2024 13:46:10 +0100 Subject: [PATCH] MOBILE-4470 core: Default to reduced motion in old devices --- src/core/services/platform.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/services/platform.ts b/src/core/services/platform.ts index a029de0b4..c08089d06 100644 --- a/src/core/services/platform.ts +++ b/src/core/services/platform.ts @@ -95,7 +95,8 @@ export class CorePlatformService extends Platform { * @returns Whether the device is configured to reduce motion. */ prefersReducedMotion(): boolean { - return window.matchMedia('(prefers-reduced-motion: reduce)').matches; + // Default to reduced motion in devices that don't support this CSS property. + return !window.matchMedia('(prefers-reduced-motion: no-preference)').matches; } /**