-
Notifications
You must be signed in to change notification settings - Fork 0
/
CSS Flexbox.html
68 lines (63 loc) · 1.67 KB
/
CSS Flexbox.html
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
56
57
58
59
60
61
62
63
64
65
66
67
68
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Flexbox</title>
<style>
.container{
border: 2px solid rgb(246, 246, 15);
display: flex;
height: 80vh;
/* justify-content: space-between; */
align-items: center;
/* flex-direction: column; */
/* flex-wrap: wrap; */
/* flex-wrap: wrap-reverse; */
/* align-content: center; */
/* There is no justify-items in flexbox; */
flex-flow: row wrap;
/* row-gap: 30px;
column-gap: 20px; */
gap: 10px 40px;
}
.item{
/* flex-grow: 1; */
height: 92px;
width: 92px;
border: 2px solid black;
/* margin: 4px; */
background-color: red;
}
.order-1{
order: 1;
}
.order-2{
order: 2;
}
.order-3{
order: 3;
}
.item1{
/* flex-grow: 2; */
/* flex-shrink: 2; */
align-self: flex-end;
}
</style>
</head>
<body>
<main>
<div class="container">
<div class="item">1</div>
<div class="item">2</div>
<div class="item">3</div>
<div class="item order-1">4</div>
<div class="item"></div>
<div class="item"></div>
<div class="item"></div>
<div class="item"></div>
<div class="item"></div>
</div>
</main>
</body>
</html>