-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapoio-classes-flexbox.html
83 lines (68 loc) · 3.09 KB
/
apoio-classes-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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<!doctype html>
<html lang="pt-br">
<head>
<title>Bootstrap - Classes flexbox</title>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="css/bootstrap.min.css">
<style type="text/css">
.caixa {
background: #f5f5f5;
height: 200px;
}
.item {
border:1px solid black;
padding: 5px;
}
</style>
</head>
<body>
<div class="container">
<h2>Flex container e flex itens (d-flex, flex-row, flex-column, flex-row-reverse)</h2>
<div class="caixa d-flex flex-row-reverse">
<div class="item">Flex item 1</div>
<div class="item">Flex item 2</div>
<div class="item">Flex item 3</div>
</div>
<br><br>
<h2>Alinhamento horizontal: justify-content-ALINHAMENTO (start, center, end, around e between)</h2>
<div class="caixa border d-flex justify-content-between">
<div class="item">Flex item 1</div>
<div class="item">Flex item 2</div>
<div class="item">Flex item 3</div>
</div>
<br><br>
<h2>Colunas (d-flex, flex-column, flex-column-reverse)</h2>
<div class="caixa d-flex flex-column-reverse">
<div class="item">Flex item 1</div>
<div class="item">Flex item 2</div>
<div class="item">Flex item 3</div>
</div>
<br><br>
<h2>Alinhamento vertical: align-items-ALINHAMENTO (start, center, end, baseline e stretch)</h2>
<div class="caixa d-flex align-items-baseline">
<div class="item" style="padding-top: 30px;">Flex item 1</div>
<div class="item">Flex item 2</div>
<div class="item" style="padding-bottom: 50px;">Flex item 3</div>
</div>
<br><br>
<h2>Alinhamento self: align-self-ALINHAMENTO (start, center, end, baseline e stretch)</h2>
<div class="caixa d-flex">
<div class="item align-self-start">Flex item 1</div>
<div class="item align-self-center">Flex item 2</div>
<div class="item align-self-end">Flex item 3</div>
<div class="item align-self-baseline">Flex item 4</div>
<div class="item align-self-stretch">Flex item 5</div>
</div>
<br><br>
</div>
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
<script src="js/bootstrap.min.js"></script>
</body>
</html>