New issue
Advanced search Search tips

Issue 695576 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Mar 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 2
Type: Bug



Sign in to add a comment

position:sticky - stickyBoxRect incorrectly excludes scrollOffset for anonymous containers.

Project Member Reported by smcgruer@chromium.org, Feb 23 2017

Issue description

(Forked from review of https://codereview.chromium.org/2708883005 which originally included a fix for this unrelated bug)

If we have an anonymous container, then skippedContainersOffset can incorrectly exclude the scrollOffset if our non-anonymous containing block is the scrollAncestor, e.g. something like:

<scroller>
  [anonymous container]
    <inline div>

This either needs to not be skipped, or has to be corrected for.
 
Labels: OS-All
Labels: -Pri-3 Pri-2
Summary: position:sticky - stickyBoxRect incorrectly excludes scrollOffset for anonymous containers. (was: sticky: stickyBoxRect incorrectly excludes scrollOffset for anonymous containers.)
I'm struggling to reproduce the conditions for this bug. It's possible we actually fixed it at some point accidentally. Will do a little more digging to try to repro.

My attempted reproduction was http://output.jsbin.com/dumepup
Status: Fixed (was: Assigned)
Yes, this appears to be fixed. The condition originally added in the CL was:

if (locationContainer != scrollAncestor &&
    containingBlock == scrollAncestor) {

For the repro above, we have:

[1:1:0324/135752.326112:10078969722:INFO:LayoutBoxModelObject.cpp(962)] "LayoutInline (sticky positioned) DIV class='inline sticky'": locationContainer: 0x2b6242218400, containingBlock: 0x2b6242218200, scrollAncestor: 0x2b6242218200

So locationContainer != scrollAncestor, containingBlock == scrollAncestor, and yet the example already works fine without any correction.

Closing as Fixed.

Sign in to add a comment