gecko-dev/layout/reftests/css-grid/grid-item-content-baseline-...

119 строки
9.4 KiB
HTML

<!DOCTYPE HTML>
<!--
Any copyright is dedicated to the Public Domain.
http://creativecommons.org/publicdomain/zero/1.0/
-->
<html><head>
<meta charset="utf-8">
<title>Reference: align-content/justify-content:baseline</title>
<link rel="author" title="Mats Palmgren" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1256429">
<link rel="stylesheet" type="text/css" href="support/ahem.css">
<style type="text/css">
html,body {
color:black; background-color:white; font-size:16px; font-family: Ahem; padding:0; margin:0;
}
.grid {
display: grid;
grid: 100px / repeat(4, auto);
}
.c {
grid: repeat(4, auto) / 100px;
}
div {
float: left;
border:2px solid;
padding:1px;
margin:1px;
}
span {
background: lime;
display: inline-block;
border: 1px solid black;
}
span:nth-child(1) { font-size:12px; }
span:nth-child(2) { font-size:32px; }
span:nth-child(3) { font-size:10px; }
.pbs { padding-block-start: 15px; margin-block-start: 5px; }
.pbe { padding-block-end: 7px; margin-block-end: 3px; }
.fb { align-self:baseline; justify-self:baseline; }
.lb { align-self:last baseline; justify-self:last baseline; }
.s { align-self:self-stretch; justify-self:self-stretch; }
.hl { writing-mode: horizontal-tb; direction:ltr; }
.hr { writing-mode: horizontal-tb; direction:rtl; }
.vl { writing-mode: vertical-lr; text-orientation: sideways; }
.vr { writing-mode: vertical-rl; text-orientation: sideways; }
.vlr { writing-mode: vertical-lr; direction:rtl; text-orientation: sideways; }
.vrl { writing-mode: vertical-rl; direction:ltr; text-orientation: sideways; }
.cbm { padding-block-start:33px; grid-template-rows: 1fr; }
.cbm2 { padding-block-start:27px; grid-template-rows: 1fr; }
.cim { padding-inline-start:33px; grid-template-columns: 1fr; }
.cim2 { padding-inline-start:27px; grid-template-columns: 1fr; }
.pe { padding-inline-end:33px; grid-template-columns: 1fr; }
.pe2 { padding-inline-end:30px; grid-template-columns: 1fr; }
.vpe { padding-block-end:33px; grid-template-rows: 1fr; }
.vpe2 { padding-block-end:32px; grid-template-rows: 1fr; }
</style>
</head>
<body>
<div class="grid hl"><span style="padding-block-start:16px;" class="fb">A<br>B</span><span class="fb">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s">X<br>Z</span></div>
<div class="grid hl"><span style="padding-block-start:16px;" class="fb pbe">A<br>B</span><span style="padding-block-start:0px;" class="fb">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s">X<br>Z</span></div>
<div class="grid vl"><span style="padding-block-start:4px;" class="fb">A<br>B</span><span style="padding-block-start:0px;" class="fb">M<br>N</span><span style="padding-block-start:4px; padding-block-end:70px;" class="fb s">X<br>Z</span></div>
<div class="grid vl"><span style="padding-block-start:15px;" class="fb pbs">A<br>B</span><span style="padding-block-start:16px;" class="fb">M<br>N</span><span style="padding-block-start:20px; padding-block-end:54px;" class="fb s">X<br>Z</span></div>
<div class="grid vr"><span style="padding-block-start:16px;" class="fb">A<br>B</span><span style="padding-block-start:0px;" class="fb">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s">X<br>Z</span></div>
<div class="grid vr"><span style="padding-block-start:16px;" class="fb pbe">A<br>B</span><span style="padding-block-start:0px;" class="fb">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s">X<br>Z</span></div>
<br clear="all">
<div class="grid hl cbm"><span style="padding-block-end:4px;" class="lb">A<br>B</span><span style="padding-block-end:0px;" class="lb">M<br>N</span></div>
<div class="grid hl cbm2"><span style="padding-block-end:7px;" class="lb pbe">A<br>B</span><span style="padding-block-end:6px;" class="lb">M<br>N</span></div>
<div class="grid vl cbm"><span style="padding-block-end:16px;" class="lb">A<br>B</span><span style="padding-block-end:0px;" class="lb">M<br>N</span></div>
<div class="grid vl cbm"><span style="padding-block-end:16px;" class="lb pbs">A<br>B</span><span style="padding-block-end:0px;" class="lb">M<br>N</span></div>
<div class="grid vr cbm"><span style="padding-block-end:4px;" class="lb">A<br>B</span><span style="padding-block-end:0px;" class="lb">M<br>N</span></div>
<div class="grid vr cbm2"><span style="padding-block-end:7px;" class="lb pbe">A<br>B</span><span style="padding-block-end:6px;" class="lb">M<br>N</span></div>
<br clear="all">
<div class="grid c hl"><span style="padding-block-start:4px;" class="fb vl">A<br>B</span><span style="padding-block-start:0px;" class="fb vl">M<br>N</span><span style="padding-block-start:4px; padding-block-end:70px;" class="fb s vl">X<br>Z</span></div>
<div class="grid c hl"><span style="padding-block-start:4px;" class="fb vl pbe">A<br>B</span><span style="padding-block-start:0px;" class="fb vl">M<br>N</span><span style="padding-block-start:4px; padding-block-end:70px;" class="fb s vl">X<br>Z</span></div>
<div class="grid c vl"><span style="padding-block-start:16px;" class="fb hl">A<br>B</span><span style="padding-block-start:0px;" class="fb hl">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s hl">X<br>Z</span></div>
<div class="grid c vl"><span style="padding-block-start:15px;" class="fb hl pbs">A<br>B</span><span style="padding-block-start:4px;" class="fb hl">M<br>N</span><span style="padding-block-start:21px; padding-block-end:53px;" class="fb s hl">X<br>Z</span></div>
<div class="grid c vr"><span style="padding-block-start:16px;" class="fb hl">A<br>B</span><span style="padding-block-start:0px;" class="fb hl">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s hl">X<br>Z</span></div>
<div class="grid c vr"><span style="padding-block-start:16px;" class="fb hl pbe">A<br>B</span><span style="padding-block-start:0px;" class="fb hl">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s hl">X<br>Z</span></div>
<br clear="all">
<div class="grid c hl cim"><span style="padding-block-end:16px;" class="lb vl">A<br>B</span><span style="padding-block-end:0px;" class="lb vl">M<br>N</span></div>
<div class="grid c hl cim"><span style="padding-block-end:13px;" class="lb vl pbe">A<br>B</span><span style="padding-block-end:0px;" class="lb vl">M<br>N</span></div>
<div class="grid c vl cim"><span style="padding-block-end:4px;" class="lb hl">A<br>B</span><span style="padding-block-end:0px;" class="lb hl">M<br>N</span></div>
<div class="grid c vl cim"><span style="padding-block-end:4px;" class="lb hl pbs">A<br>B</span><span style="padding-block-end:0px;" class="lb hl">M<br>N</span></div>
<div class="grid c vr cim"><span style="padding-block-end:4px;" class="lb hl">A<br>B</span><span style="padding-block-end:0px;" class="lb hl">M<br>N</span></div>
<div class="grid c vr cim2"><span style="padding-block-end:7px;" class="lb hl pbe">A<br>B</span><span style="padding-block-end:6px;" class="lb hl">M<br>N</span></div>
<br clear="all">
<div class="grid c hl"><span style="padding-block-start:16px;" class="fb vr">A<br>B</span><span style="padding-block-start:0px;" class="fb vr">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s vr">X<br>Z</span></div>
<div class="grid c hl"><span style="padding-block-start:13px;" class="fb vr pbe">A<br>B</span><span style="padding-block-start:0px;" class="fb vr">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s vr">X<br>Z</span></div>
<div class="grid vl"><span style="padding-block-start:16px;" class="fb vr">A<br>B</span><span style="padding-block-start:0px;" class="fb vr">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s vr">X<br>Z</span></div>
<div class="grid vl"><span style="padding-block-start:16px;" class="fb vr pbs">A<br>B</span><span style="padding-block-start:0px;" class="fb vr">M<br>N</span><span style="padding-block-start:17px; padding-block-end:57px;" class="fb s vr">X<br>Z</span></div>
<div class="grid vr"><span style="padding-block-start:4px;" class="fb vl">A<br>B</span><span style="padding-block-start:0px;" class="fb vl">M<br>N</span><span style="padding-block-start:4px; padding-block-end:70px;" class="fb s vl">X<br>Z</span></div>
<div class="grid vr"><span style="padding-block-start:1px;" class="fb vl pbe">A<br>B</span><span style="padding-block-start:0px;" class="fb vl">M<br>N</span><span style="padding-block-start:4px; padding-block-end:70px;" class="fb s vl">X<br>Z</span></div>
<br clear="all">
<div class="grid c hl pe"><span style="padding-block-end:4px;" class="lb vr">A<br>B</span><span style="padding-block-end:0px;" class="lb vr">M<br>N</span></div>
<div class="grid c hl pe2"><span style="padding-block-end:7px;" class="lb vr pbe">A<br>B</span><span style="padding-block-end:3px;" class="lb vr">M<br>N</span></div>
<div class="grid vl vpe"><span style="padding-block-end:4px;" class="lb vr">A<br>B</span><span style="padding-block-end:0px;" class="lb vr">M<br>N</span></div>
<div class="grid vl vpe2"><span style="padding-block-end:0px;" class="lb vr pbs">A<br>B</span><span style="padding-block-end:1px;" class="lb vr">M<br>N</span></div>
<div class="grid vr vpe"><span style="padding-block-end:16px;" class="lb vl">A<br>B</span><span style="padding-block-end:0px;" class="lb vl">M<br>N</span></div>
<div class="grid vr vpe"><span style="padding-block-end:16px;" class="lb vl pbe">A<br>B</span><span style="padding-block-end:0px;" class="lb vl">M<br>N</span></div>
</body>
</html>