Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[css-contain] Layout containment abspos and fixed descendants #11026

Merged
merged 1 commit into from May 16, 2018

Conversation

chromium-wpt-export-bot
Copy link
Collaborator

@chromium-wpt-export-bot chromium-wpt-export-bot commented May 16, 2018

An element with "contain: layout" should be the containing block
of any absolutely or fixed positioned descendants.

The spec is very clear regarding this
(https://drafts.csswg.org/css-contain/#containment-layout):
"The element acts as a containing block for absolutely positioned
and fixed positioned descendants."

The patch just adds a new condition to
ComputedStyle::CanContainFixedPositionObjects().

We already had the condition for paint containment before,
so this takes advantage to add WPT tests to verify that case too.

This patch causes that contain-layout-005.html starts to fail,
but that's because of crbug.com/843329.
There are more failing tests related to that bug, so TestExpectations
is modified to reference it.

BUG=785212
TEST=external/wpt/css/css-contain/contain-layout-006.html
TEST=external/wpt/css/css-contain/contain-layout-007.html

Change-Id: I8bb1d637bd7742961a414a5007b8ee8a8d3e66ea
Reviewed-on: https://chromium-review.googlesource.com/1059557
Reviewed-by: Morten Stenshorne mstensho@chromium.org
Commit-Queue: Manuel Rego Casasnovas rego@igalia.com
Cr-Commit-Position: refs/heads/master@{#559045}

Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already reviewed downstream.

An element with "contain: layout" should be the containing block
of any absolutely or fixed positioned descendants.

The spec is very clear regarding this
(https://drafts.csswg.org/css-contain/#containment-layout):
"The element acts as a containing block for absolutely positioned
 and fixed positioned descendants."

The patch just adds a new condition to
ComputedStyle::CanContainFixedPositionObjects().

We already had the condition for paint containment before,
so this takes advantage to add WPT tests to verify that case too.

This patch causes that contain-layout-005.html starts to fail,
but that's because of crbug.com/843329.
There are more failing tests related to that bug, so TestExpectations
is modified to reference it.

BUG=785212
TEST=external/wpt/css/css-contain/contain-layout-006.html
TEST=external/wpt/css/css-contain/contain-layout-007.html

Change-Id: I8bb1d637bd7742961a414a5007b8ee8a8d3e66ea
Reviewed-on: https://chromium-review.googlesource.com/1059557
Reviewed-by: Morten Stenshorne <mstensho@chromium.org>
Commit-Queue: Manuel Rego Casasnovas <rego@igalia.com>
Cr-Commit-Position: refs/heads/master@{#559045}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants