-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflex2.html
More file actions
55 lines (44 loc) · 822 Bytes
/
flex2.html
File metadata and controls
55 lines (44 loc) · 822 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
.container {
display: flex;
height: 300px;
align-items: center;
justify-content: center;
}
.item {
width: 100px;
height: 100px;
background-color: lightblue;
border: 1px solid black;
box-sizing: border-box;
margin: 10px;
}
.item1 {
align-self: flex-start;
order: 2;
}
.item2 {
align-self: center;
order: 3;
}
.item3 {
align-self: flex-end;
order: 1;
}
</style>
</head>
<body>
<div class="container">
<div class="item item1">1</div>
<div class="item item2">2</div>
<div class="item item3">3</div>
</div>
</body>
</html>