New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 607380 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: May 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug



Sign in to add a comment

scrollIntoView() scrolls unnecessary elements

Project Member Reported by tkent@chromium.org, Apr 28 2016

Issue description

Version: 50 stable and 52 canary
OS: Maybe all

What steps will reproduce the problem?
(1) Load the following HTML
(2) Observe

<!DOCTYPE html>
<body>
A red box should not appear.
<input style="background:gray; width:200px;" autofocus onfocus="document.getElementById('t').scrollIntoView()">
<div style="overflow:scroll; background:#8cf; height:202px; positin:relative">
 <div style="border:1px solid white; height:200px;"></div>
 <div style="background:red; height:200px;"></div>
 <div id=t tabindex=0 style="background:lime; position:absolute; top:400px;">foo</div>
</div>
</body>

What is the expected output?
No red box.

What do you see instead?
There is a red box because the parent element of position:absolute was scrolled unnecessarily.

Please use labels and text to provide additional information.
Safari Preview: NG
Firefox: OK
Edge: OK

This issue was found on investigating  Issue 601341 .

 

Comment 1 by tkent@chromium.org, Apr 28 2016

Owner: tkent@chromium.org
Status: Started (was: Untriaged)

Comment 2 by tkent@chromium.org, Apr 28 2016

Owner: ----
Status: Untriaged (was: Started)
Note that "positin:relative" in the first DIV is not wrong.  The intention is it has no position:relative.

Comment 3 by e...@chromium.org, Apr 28 2016

Status: Available (was: Untriaged)

Comment 4 by bokan@chromium.org, Apr 28 2016

Cc: bokan@chromium.org ymalik@chromium.org
Labels: Hotlist-Input-Dev OS-All
Repro case posted to bokan.ca/bugs/607380.html.

Yup, this looks like a bug in LayoutBox::scrollRectToVisible, likely we calculate the parent incorrectly when calling enclosingScrollableBox.
Project Member

Comment 5 by sheriffbot@chromium.org, May 1 2017

Labels: Hotlist-Recharge-Cold
Status: Untriaged (was: Available)
This issue has been available for more than 365 days, and should be re-evaluated. Please re-triage this issue.
The Hotlist-Recharge-Cold label is applied for tracking purposes, and should not be removed after re-triaging the issue.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Status: WontFix (was: Untriaged)
No longer reproduces in Chrome 58.0.3029.81. Closing old issue.

Sign in to add a comment