-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathitem-using-flex.html
More file actions
executable file
·39 lines (37 loc) · 1.05 KB
/
item-using-flex.html
File metadata and controls
executable file
·39 lines (37 loc) · 1.05 KB
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
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Photo Gallery</title>
<!-- CSS -->
<link rel="stylesheet" href="css/app.css">
</head>
<body>
<div class="main-container">
<button>
<a href="/">Back</a>
</button>
<h2>Using flex with flex item</h2>
<p>This property is a shorthand property for the flex-grow, flex-shrink, and flex-basis properties. It will accept which prop comes first</p>
<div class="flex-container">
<h3>Without flex</h3>
<div class="flex-item-flex">
<div>One</div>
<div>Two</div>
<div>Three</div>
<div>Four</div>
<div>Five</div>
</div>
<h3>Using flex</h3>
<div class="flex-item-flex">
<div>One</div>
<div style="flex:1 1 auto">Two</div>
<div>Three</div>
<div>Four</div>
<div style="flex: 1 2 50px">Five</div>
</div>
</div>
</div>
</body>
</html>