Closed Bug 1753565 Opened 4 years ago Closed 3 years ago

If users set prefers-reduced-motion through system settings, then Firefox should not fire "Smooth Scrolling."

Categories

(Core :: Layout: Scrolling and Overflow, enhancement, P3)

Firefox 95
enhancement

Tracking

()

RESOLVED FIXED
114 Branch
Accessibility Severity s3
Tracking Status
firefox114 --- fixed

People

(Reporter: erwinm, Assigned: dlrobertson)

References

(Regressed 2 open bugs)

Details

(Keywords: access)

Attachments

(2 files)

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:95.0) Gecko/20100101 Firefox/95.0

Steps to reproduce:

Use your system settings to indicate prefers-reduced-motion. For example, in MacOS, open System Preferences > Accessibility > Display and check Reduce motion.

Open Firefox with its default settings, e.g. using Mozregression.

Open about:preferences.

Tab out of the search box.

Page Down.

Actual results:

Firefox turns Page Down into animated "Smooth Scrolling."

This can trigger migraines.

See https://www.menieres.org.uk/information-and-support/day-to-day/vision-and-vertigo

https://dizziness-and-balance.com/disorders/visual/visual_vertigo.html

etc.

Most sources note trouble with scrolling in general, not mentioning smooth scrolling in particular, but replacing Page Down with scrolling adds more scrolling, with less user control, in any case.

Expected results:

If users have set prefers-reduced-motion, Firefox should turn off "Smooth Scrolling."

Summary: If users set prefers-reduced-motion through synstem settings, then Firefox should not fire "Smooth Scrolling." → If users set prefers-reduced-motion through system settings, then Firefox should not fire "Smooth Scrolling."

Enabling this in system settings would make it easier for users who get migraines from the default settings to configure Firefox, and to bibisect bugs in Firefox.

This could be an enhancement. I'll set a component to involve the dev team. If it's not the correct component please feel free to change it.
Thanks!

Status: UNCONFIRMED → NEW
Ever confirmed: true
Component: Untriaged → Preferences
Keywords: access
Component: Preferences → Layout: Scrolling and Overflow
Product: Firefox → Core
Duplicate of this bug: 1798659

The following field has been copied from a duplicate bug:

Field Value Source
Whiteboard [access-s3] bug 1798659

For more information, please visit auto_nag documentation.

Whiteboard: [access-s3]
See Also: → 1794328

Today I realized there's a spec text;

User agents should follow platform conventions, if any.

Priority: -- → P3
Assignee: nobody → drobertson

I can reproduce this. When general.smoothScroll=false, I see the correct behavior, so I think we just need to propagate system settings to general.smoothScroll=false. I'm not sure if this is done elsewhere.

If the user has set prefers reduced motion, we should disable smooth scrolls. In
practice, the system setting prefers reduced motion should be equivalent to the
user setting general.smoothScroll=false.

This looks surprisingly similar to bug 1584859, thanks for doing this!

(In reply to Emilio Cobos Álvarez (:emilio) from comment #8)

This looks surprisingly similar to bug 1584859, thanks for doing this!

Good catch! I hadn't seen that one... After looking at D48010, I think the current patch I have here could use some work.

See Also: → 1584859
Attachment #9322776 - Attachment description: Bug 1753565 - prefers reduced motion should disable smooth scrolls. r=botond,hiro → Bug 1753565 - Disable smooth scrolls if prefers-reduced-motion. r=hiro,botond,emilio

Disable the prefers-reduced-motion preference for mochitests and
web-platform-tests.

Depends on D172446

Pushed by drobertson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/947534ff1319 Disable smooth scrolls if prefers-reduced-motion. r=botond https://hg.mozilla.org/integration/autoland/rev/817b0cf1e4e0 Disable prefers-reduced-motion for tests. r=botond
Regressions: 1828572
Regressions: 1828575

Backed out for causing bc failures in browser_proton_moreTools_panel.js

and also: https://treeherder.mozilla.org/logviewer?job_id=412809120&repo=autoland

Flags: needinfo?(drobertson)

See Bug 1828575.

This should not unconditionally disable smooth scrolling.
For new users (new profiles), the default is to disable smooth scrolling.
However, users should be able to enable smooth scrolling from the settings (like Chrome).

For existing users (used profiles) 、in consideration of the user experience, this should not change their existing smooth scrolling behavior.

(In reply to Alice0775 White from comment #13)

See Bug 1828575.

This should not unconditionally disable smooth scrolling.
For new users (new profiles), the default is to disable smooth scrolling.
However, users should be able to enable smooth scrolling from the settings (like Chrome).

For existing users (used profiles) 、in consideration of the user experience, this should not change their existing smooth scrolling behavior.

Thanks, this makes sense and I had a prior patchset that did this. I'll update the patches to do this.

Flags: needinfo?(drobertson)

After thinking about it a bit more I don't think I fully understand the scenario in which the user would get into this state. We don't ever actually change the value of general.smoothScroll, so I don't know how we'd detect "the user has prefers-reduced-motion set, but also wants smooth scrolls".

Flags: needinfo?(alice0775)

I think it would be sufficient for this bug to do the following...

  1. Is the browser running with the new profile?
    if yes go to step 2 else end
  2. Is the OS set to prefers-reduced-motion?
    if yes go to step 3 else end
  3. Set general.smoothScroll to false
  4. end
Flags: needinfo?(alice0775)

In some versions of Firefox, new profiles started with smooth scroll enabled, among other animations.

This can make motion-senstive users sick, and can make it harder for us to configure Firefox for safe use. The idea was to use the system settings as a quick switch. Overriding about:config settings may not be the best option, but what is?

  • Starting new installations with all of these off?

  • Having new installations check system settings?

  • Having 2 versions of Firefox to download with different starting about:config settings?

Attachment #9322776 - Attachment description: Bug 1753565 - Disable smooth scrolls if prefers-reduced-motion. r=hiro,botond,emilio → Bug 1753565 - Default disable smooth scrolls if prefers-reduced-motion. r=hiro,botond,emilio
Pushed by drobertson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/1c5305d4d10a Default disable smooth scrolls if prefers-reduced-motion. r=botond https://hg.mozilla.org/integration/autoland/rev/d454667254ed Disable prefers-reduced-motion for tests. r=botond
Pushed by drobertson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/a2f066123f3c Default disable smooth scrolls if prefers-reduced-motion. r=botond https://hg.mozilla.org/integration/autoland/rev/6fb66b5e6153 Disable prefers-reduced-motion for tests. r=botond
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 114 Branch
Flags: needinfo?(drobertson)
Regressions: 1830103
Accessibility Severity: --- → s3
Whiteboard: [access-s3]
Duplicate of this bug: 1584859
See Also: → 1851024
Regressions: 1856196
Regressions: 1865782

This bug came up during a recent APZ meeting because it has caused a number of regressions that have been tricky to diagnose (bug 1851024, likely bug 1862645) or fix (bug 1865782).

While considering potential alternatives, we discussed the alternative suggested in comment 16, and I wanted to record the reason we did not initially choose this approach:

(In reply to Alice0775 White from comment #16)

I think it would be sufficient for this bug to do the following...

  1. Is the browser running with the new profile?
    if yes go to step 2 else end
  2. Is the OS set to prefers-reduced-motion?
    if yes go to step 3 else end
  3. Set general.smoothScroll to false
  4. end

This approach would not address the following use case:

  • A user who prefers reduced motion sits down at a computer (maybe not their own) that doesn't currently have the OS setting enabled
  • The user enables the OS prefers-reduced-motion setting
  • The new setting takes effect in all applications including existing Firefox profiles

I'm not sure how important this use case is; if we feel it's not that important, we could consider switching to this approach, which would both significantly reduce the implementation complexity and avoid the mentioned regressions.

Note, Dan has found that other browsers do respect an OS preference change in existing profiles, so switching to this approach would mean behaving differently from other browsers.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: