File tree Expand file tree Collapse file tree 3 files changed +54
-4
lines changed Expand file tree Collapse file tree 3 files changed +54
-4
lines changed Original file line number Diff line number Diff line change @@ -154,4 +154,4 @@ <h4>Related posts</h4>
154
154
</ footer >
155
155
</ div >
156
156
</ body >
157
- </ html >
157
+ </ html >
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ <h6>The Basic Language of the Web: HTML</h6>
18
18
-->
19
19
20
20
< div class ="container ">
21
- < header class ="main-header ">
21
+ < header class ="main-header clearfix ">
22
22
< h1 > 📘 The Code Magazine</ h1 >
23
23
24
24
< nav >
@@ -28,6 +28,8 @@ <h1>📘 The Code Magazine</h1>
28
28
< a href ="# "> Flexbox</ a >
29
29
< a href ="# "> CSS Grid</ a >
30
30
</ nav >
31
+
32
+ <!-- <div class="clear"></div> -->
31
33
</ header >
32
34
33
35
< article >
@@ -39,9 +41,10 @@ <h2>The Basic Language of the Web: HTML</h2>
39
41
alt ="Headshot of Laura Jones "
40
42
height ="50 "
41
43
width ="50 "
44
+ class ="author-img "
42
45
/>
43
46
44
- < p id ="author ">
47
+ < p id ="author " class =" author " >
45
48
Posted by < strong > Laura Jones</ strong > on Monday, June 21st 2027
46
49
</ p >
47
50
Original file line number Diff line number Diff line change 14
14
}
15
15
16
16
.container {
17
- width : 800 px ;
17
+ width : 1200 px ;
18
18
/* margin-left: auto;
19
19
margin-right: auto; */
20
20
margin : 0 auto;
@@ -265,3 +265,50 @@ footer p {
265
265
nav p {
266
266
font-size: 18px;
267
267
} */
268
+
269
+ /* Using Floats */
270
+ .author-img {
271
+ float : left;
272
+ }
273
+
274
+ .author {
275
+ /* padding-left: 80px; */
276
+ margin-top : 10px ;
277
+ margin-left : 10px ;
278
+ float : left;
279
+ }
280
+
281
+ h1 {
282
+ float : left;
283
+ }
284
+
285
+ nav {
286
+ float : right;
287
+ }
288
+
289
+ .clear {
290
+ clear : both;
291
+ }
292
+
293
+ .clearfix ::after {
294
+ clear : both;
295
+ content : "" ;
296
+ display : block;
297
+ }
298
+ article {
299
+ /* background-color: green; */
300
+ width : 825px ;
301
+ float : left;
302
+ }
303
+
304
+ aside {
305
+ /* background-color: red; */
306
+ width : 300px ;
307
+ float : right;
308
+ }
309
+
310
+ footer {
311
+ width : 1200 ;
312
+ clear : both;
313
+ /* background-color: blue; */
314
+ }
You can’t perform that action at this time.
0 commit comments