Merge pull request #3922 from NoelDeMartin/MOBILE-4470

MOBILE-4470: Tweaks
main
Dani Palou 2024-02-01 16:58:41 +01:00 committed by GitHub
commit 88931bd50d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 2 deletions

View File

@ -234,7 +234,7 @@ class behat_app_helper extends behat_base {
$this->runtime_js("init($initoptions)"); $this->runtime_js("init($initoptions)");
} catch (Exception $error) { } catch (Exception $error) {
throw new DriverException('Moodle App not running or not running on Automated mode.'); throw new DriverException('Moodle App not running or not running on Automated mode: ' . $error->getMessage());
} }
if ($restart) { if ($restart) {

View File

@ -95,7 +95,8 @@ export class CorePlatformService extends Platform {
* @returns Whether the device is configured to reduce motion. * @returns Whether the device is configured to reduce motion.
*/ */
prefersReducedMotion(): boolean { 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;
} }
/** /**