New issue
Advanced search Search tips

Issue 767937 link

Starred by 4 users

Issue metadata

Status: WontFix
Owner:
Closed: Jan 7
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 2
Type: Bug



Sign in to add a comment

element.scrollIntoView with smooth behavior should animate scrollers simultaneously as opposed to sequentially

Reported by jmeniche...@gmail.com, Sep 22 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:55.0) Gecko/20100101 Firefox/55.0

Steps to reproduce the problem:
Me and other developers wrote a polyfill that matches current Firefox implementation and I think scrollIntoView animation when there's a nested scrollable element doesn't look 'smooth'.

1. Go to https://iamdustan.com/smoothscroll
2. Scroll down to element.scrollIntoView example and click SCROLL INTO VIEW button
3. COmpare the behavior and animation between Firefox implementation, Chrome Implementation in v61 and Safari polyfilled behavior

What is the expected behavior?
Container element and body should scroll at the same time respecting simultaneous easing.

What went wrong?
Not only the elements get centered which honestly I don't know if it's expected. I do know it's harder to polyfilled and that right Chrome is stacking the animations that kills the smooth feel.

Did this work before? N/A 

Does this work in other browsers? Yes

Chrome version: 61.0.3163.100 (Build oficial) (64 bits)  Channel: stable
OS Version: OS X 10.12
Flash Version: Shockwave Flash 21.0 r0
 
Labels: Needs-Triage-M61
Cc: sunyunjia@chromium.org
Labels: Hotlist-Input-Dev
Owner: majidvp@chromium.org
Status: Assigned (was: Unconfirmed)
majidvp@ can you take a look?
Cc: -sunyunjia@chromium.org bokan@chromium.org ajuma@chromium.org majidvp@chromium.org
Labels: -Hotlist-Interop OS-Android OS-Chrome OS-Linux OS-Windows
Owner: sunyunjia@chromium.org
Summary: element.scrollIntoView with smooth behavior should animate scrollers simultaneously as opposed to sequentially (was: element.scrollIntoView with smooth behavior animates in a weird way)
This is indeed the designed behavior. See SmoothScrollSequencer which is responsible to sequence the smooth scroll animations from outer most
scroller to the inner one.

AFAIK, the spec does not specify the order by which we should animate so
this is not really an interop issue just different UX.  /cc bokan@ and ajuma@ in case they have opinion one way or another in terms of UX.

As for centering the elements by default, I think there was some confusion
on the spec front on how the default behavior should be. I opened an issue
with FF [2] and recently the spec changed away from 'center' being default
to 'start' being the default [3]. Matching that change is being tracked in
 Issue 764282 .


[1]https://codesearch.chromium.org/chromium/src/third_party/WebKit/Source/platform/scroll/SmoothScrollSequencer.h
[2] https://bugzilla.mozilla.org/show_bug.cgi?id=1389274
[3] https://github.com/w3c/csswg-drafts/pull/1505






 


Sandra, Majid, any update on this bug?
Status: WontFix (was: Assigned)

Sign in to add a comment