forked from mirrors/gecko-dev
Automatic update from web-platform-tests [last-baseline] Propagate last baslines from flexbox. This modifies flex's baseline accumulator to support three(!) potential baselines for the first & last baseline. Firstly we prefer the major/minor baseline for the first/last baseline of the first/last line. Then we prefer the minor/major baseline for the first/last baseline of the first/last line. Finally fallback baseline is the first/last item in the first/last line. Bug: 885175 Change-Id: I8113c48e3f6861895f89585f39fd9268e5d70f65 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3914072 Commit-Queue: Ian Kilpatrick <ikilpatrick@chromium.org> Reviewed-by: David Grogan <dgrogan@chromium.org> Cr-Commit-Position: refs/heads/main@{#1053037} -- wpt-commits: 1d9f9d7a867d22623a00574a4767a718eb9a77a9 wpt-pr: 36146
65 lines
1.6 KiB
HTML
65 lines
1.6 KiB
HTML
<!DOCTYPE html>
|
|
<!--
|
|
Any copyright is dedicated to the Public Domain.
|
|
http://creativecommons.org/publicdomain/zero/1.0/
|
|
-->
|
|
<!-- Reference case, using inline-block instead of inline-flex, and with the
|
|
baseline-aligned items aligned using specific font-size / line-heights,
|
|
and with unaligned children taken out of baseline-alignment using
|
|
"float: left".
|
|
-->
|
|
<html>
|
|
<head>
|
|
<title>CSS Reftest Reference</title>
|
|
<link rel="author" title="Daniel Holbert" href="mailto:dholbert@mozilla.com">
|
|
<meta charset="utf-8">
|
|
<style>
|
|
.flexContainer {
|
|
display: inline-block;
|
|
/* Split testcase's 40px width into 20px of padding-right and 20px of
|
|
width, to set aside space for the testcase's (invisible) second line.
|
|
*/
|
|
width: 20px;
|
|
padding-right: 20px;
|
|
height: 40px;
|
|
background: lightblue;
|
|
}
|
|
.flexContainer > * {
|
|
width: 20px;
|
|
height: 20px;
|
|
display: inline-block;
|
|
}
|
|
|
|
.smallFont {
|
|
font-size: 8px;
|
|
line-height: 8px;
|
|
}
|
|
.medFont {
|
|
font-size: 12px;
|
|
line-height: 12px;
|
|
}
|
|
.bigFont {
|
|
font-size: 16px;
|
|
line-height: 16px;
|
|
}
|
|
.unaligned { float: left }
|
|
</style>
|
|
</head>
|
|
<body>
|
|
a
|
|
<!-- Flex containers with flex items that have a mix of baselines: -->
|
|
<div class="flexContainer medFont">
|
|
<div class="bigFont">d</div
|
|
><br><div class="medFont unaligned">e</div>
|
|
</div>
|
|
|
|
<!-- Flex container with second line baseline-aligned
|
|
(shouldn't make a difference) -->
|
|
<div class="flexContainer smallFont">
|
|
<div class="bigFont">l</div
|
|
><br><div class="medFont unaligned">m</div>
|
|
</div>
|
|
n
|
|
|
|
</body>
|
|
</html>
|