3 Any copyright is dedicated to the Public Domain.
4 http://creativecommons.org/publicdomain/zero/1.0/
8 <title>Reference: align-self (part
2 of
2)
</title>
9 <link rel=
"author" title=
"Mats Palmgren" href=
"https://bugzilla.mozilla.org/show_bug.cgi?id=1151213">
10 <style type=
"text/css">
12 color:black
; background-color:white
; font-size:16px; padding:0; margin:0;
14 separator
{ clear:both
; display:block
; height:6px; }
21 /* border-block-start: 2px solid blue; */
22 border-block-start: 2px solid black
;
26 background: lightgrey
;
31 inset-inline-start:1px;
35 border-block-start: 3px solid lightgrey
;
43 border-block-start: 2px solid blue
;
44 border-inline-start: 2px solid lime
;
45 margin: 1px 1px 2px 2px;
51 top:0;left:0;bottom:0;right:0;
52 background: lightgrey
;display:none
;
54 abs1
{ grid-area: 1 / 1 / 2 / 4; }
55 abs2
{ grid-area: 1 / 1 / 4 / 2; }
56 abs3
{ grid-area: 1 / 3 / 4 / 4; }
57 abs4
{ grid-area: 3 / 1 / 4 / 4; }
59 .hl { writing-mode: horizontal-tb
; direction:ltr
; }
60 .hr { writing-mode: horizontal-tb
; direction:rtl
; }
61 .vl { writing-mode: vertical-lr
; }
62 .vr { writing-mode: vertical-rl
; }
63 .vlr { writing-mode: vertical-lr
; direction:rtl
; }
64 .vrl { writing-mode: vertical-rl
; direction:ltr
; }
66 .astart { align-self:start
; }
67 .aend { align-self:end
; }
68 .aflexstart { align-self:flex-start
; }
69 .aflexend { align-self:flex-end
; }
70 .aselfstart { align-self:self-start
; }
71 .aselfend { align-self:self-end
; }
72 .acenter { margin-right:2px; }
73 .aleft { align-self:left
; }
74 .aright { align-self:right
; }
75 .astretch1 { align-self:stretch
; }
76 .astretch2 { align-self:stretch
; width:13px; height:0; }
77 .astretch3 { align-self:stretch
; height:0; }
78 .astretch4 { align-self:stretch
; width:auto
; }
79 .astretch5 { align-self:stretch
; width:auto
; max-width:13px; }
80 .astretch6 { align-self:stretch
; height:0; max-height:9px; }
81 .astretch7 { align-self:stretch
; width:auto
; height:0; max-width:13px; max-height:9px; }
82 .aauto { align-self:auto
; }
84 .vr .aend, .vr .aflexend { margin-right:3px; }
85 .vlr .aend, .vlr .aflexend { margin-left:4px; }
86 .vlr .acenter { margin-left:3px; }
87 .vrl .aend, .vrl .aflexend { margin-right:3px; }
89 .astretch6 { width:13px; }
90 .astretch5 { width:14px; }
91 .astretch4, .astretch7 { width:15px; }
98 var gridwm
= [ "vr", "vlr", "vrl" ]; // grid-item-align-001.html tests hl/hr/vl
99 var wm
= [ "hl", "hr", "vl", "vr", "vlr", "vrl" ];
100 var test
= [ "start", "end", "flexstart", "flexend", "center", "left", "right",
101 "stretch1", "stretch2", "stretch3", "stretch4", "stretch5",
102 "stretch6", "stretch7", "auto" ];
103 for (var i
= 0; i
< gridwm
.length
; ++i
) {
104 for (var j
= 0; j
< wm
.length
; ++j
) {
105 for (var k
= 0; k
< test
.length
; ++k
) {
106 var div
= document
.createElement("div");
107 div
.className
= "grid " + gridwm
[i
];
108 var wrap
= document
.createElement("wrap");
109 div
.appendChild(wrap
);
110 var span
= document
.createElement("span");
111 span
.className
= wm
[j
] + " a" + test
[k
];
112 wrap
.appendChild(span
);
113 div
.appendChild(document
.createElement("abs1"));
114 div
.appendChild(document
.createElement("abs2"));
115 div
.appendChild(document
.createElement("abs3"));
116 div
.appendChild(document
.createElement("abs4"));
118 document
.body
.appendChild(div
)
120 document
.body
.appendChild(document
.createElement("separator"));