Skip to content

Commit

Permalink
Bug 1748799 [wpt PR 32268] - Fieldset: Fix scrollable block size with…
Browse files Browse the repository at this point in the history
… max-height and LEGEND, a=testonly

Automatic update from web-platform-tests
Fieldset: Fix scrollable block size with max-height and LEGEND

We need to take into account of LEGEND block size on computing maximum
content block size.
Also, max_content_block_size should have a lower limit for smaller
max-height. For example, NGFieldsetLayoutAlgorithmTest.ZeroMaxHeight
needs the lower limit.

Bug: 1282408
Change-Id: I6766465e9dd817ff668b9997c79aa874faa3db3e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3367584
Reviewed-by: Morten Stenshorne <[email protected]>
Auto-Submit: Kent Tamura <[email protected]>
Commit-Queue: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/main@{#956373}

--

wpt-commits: 819f257ec64f1c400d0340f288a72cf1c4796fbe
wpt-pr: 32268
  • Loading branch information
tkent-google authored and moz-wptsync-bot committed Jan 11, 2022
1 parent 6630ddd commit a9fb1a0
Show file tree
Hide file tree
Showing 2 changed files with 66 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,17 @@
max-height: 50px;
overflow: scroll;
}

.fieldset3 {
width: 20em;
max-height: 250px;
padding: 7px;
margin: 0;
overflow: auto;
box-sizing: border-box;
border: 1em solid transparent;
border-top: 40px solid transparent;
}
</style>
<p>There should be no red.</p>
<div class=fieldset>
Expand All @@ -33,3 +44,21 @@
<div class=fieldset2>
<div style="height:200px; background:blue"></div>
</div>

<div class="fieldset3">
<p>
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
</p>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,22 @@
overflow: scroll;
}

#f3 {
width: 20em;
max-height: 250px;
padding: 7px;
overflow: auto;
box-sizing: border-box;
border-color: transparent;
background: transparent;
}

#f3 legend {
height: 40px;
border: none;
color: transparent;
background: transparent;
}
</style>
<p>There should be no red.</p>
<fieldset id="f1">
Expand All @@ -43,3 +59,24 @@
<script>
document.getElementById('last').scrollIntoView();
</script>

<!-- crbug.com/1282408 -->
<fieldset id="f3">
<legend>Legend</legend>
<p>
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
The quick brown fox jumps over the lazy dog.
</p>
</fieldset>

0 comments on commit a9fb1a0

Please sign in to comment.