Skip to content

Commit 6d906b9

Browse files
author
Ronan
committed
Spacing and aligning flex items
1 parent 8c5a371 commit 6d906b9

File tree

2 files changed

+26
-4
lines changed

2 files changed

+26
-4
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"editor.formatOnSave": true
3+
}

starter/04-CSS-Layouts/flexbox.html

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,32 @@
3636
/* STARTER */
3737
font-family: sans-serif;
3838
background-color: #ddd;
39-
font-size: 34px;
39+
font-size: 32px;
4040
margin: 40px;
4141

4242
/* FLEXBOX */
4343
display: flex;
4444
align-items: center;
45-
justify-content: space-between;
45+
justify-content: flex-start;
46+
gap: 30px;
47+
}
48+
49+
.el {
50+
/* margin-right: 30px; */
51+
}
52+
53+
.el--1 {
54+
align-self: flex-start;
55+
/* order: 2; */
56+
}
57+
58+
.el--5 {
59+
align-self: stretch;
60+
order: 1;
61+
}
62+
63+
.el--6 {
64+
order: -1;
4665
}
4766
</style>
4867
</head>
@@ -54,8 +73,8 @@
5473
<div class="el el--4">are</div>
5574
<div class="el el--5">amazing</div>
5675
<div class="el el--6">languages</div>
57-
<div class="el el--7">to</div>
58-
<div class="el el--8">learn</div>
76+
<!-- <div class="el el--7">to</div>
77+
<div class="el el--8">learn</div> -->
5978
</div>
6079
</body>
6180
</html>

0 commit comments

Comments
 (0)