Skip to content

Commit ff17268

Browse files
lilleschromium-wpt-export-bot
authored andcommitted
Do not propagate body styles when html root or body is contained
Per resolution in [1]. [1] w3c/csswg-drafts#5913 Bug: 1215265 Change-Id: I50f142245cdb55b422f8a6f3d9690444bf3648aa
1 parent 2ecf81b commit ff17268

7 files changed

+59
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
>
2+
<meta charset="utf-8">
3+
<title>CSS Backgrounds and Borders Test: Do not propagate body background when html root is containedtitle>
4+
<link rel="help" href="https://drafts.csswg.org/css-backgrounds/#special-backgrounds">
5+
<link rel="match" href="../reference/blank.html">
6+
<style>
7+
html { contain: paint; }
8+
body { background: red; }
9+
style>
10+
<body>body>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
>
2+
<meta charset="utf-8">
3+
<title>CSS Test Referencetitle>
4+
<div style="overflow:scroll">PASS if BODY has scrollbars, but not viewport.div>
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
>
2+
<meta charset="utf-8">
3+
<title>CSS Test: HTML root containment stops overflow propagation from BODYtitle>
4+
<link rel="help" href="https://drafts.csswg.org/css-overflow/#overflow-propagation">
5+
<link rel="match" href="overflow-body-propagation-011-ref.html">
6+
<style>
7+
html {
8+
contain: paint;
9+
}
10+
body {
11+
overflow: scroll;
12+
}
13+
style>
14+
<body>PASS if BODY has scrollbars, but not viewport.body>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
>
2+
<meta charset="utf-8">
3+
<title>CSS Test Referencetitle>
4+
<body style="margin:0">This text should be left aligned.body>
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
>
2+
<meta charset="utf-8">
3+
<title>CSS Writing Modes Test: Do not propagate direction from body when html root is containedtitle>
4+
<link rel="help" href="https://drafts.csswg.org/css-writing-modes/#principal-flow">
5+
<link rel="match" href="direction-propagation-body-contain-root-ref.html">
6+
<style>
7+
html { contain: paint; }
8+
body { direction: rtl; display: inline; }
9+
style>
10+
<body>body>
11+
<script>
12+
document.documentElement.insertBefore(document.createTextNode("This text should be left aligned."), document.body);
13+
script>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
>
2+
<meta charset="utf-8">
3+
<title>CSS Test Referencetitle>
4+
<div style="writing-mode:vertical-rl">This text should run vertically on the left sidebody>
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
>
2+
<meta charset="utf-8">
3+
<title>CSS Writing Modes Test: Do not propagate writing-mode from body when html root is containedtitle>
4+
<link rel="help" href="https://drafts.csswg.org/css-writing-modes/#principal-flow">
5+
<link rel="match" href="wm-propagation-body-contain-root-ref.html">
6+
<style>
7+
html { contain: paint; }
8+
body { writing-mode: vertical-rl; }
9+
style>
10+
<body>This text should run vertically on the left sidebody>

0 commit comments

Comments
 (0)