Skip to content

Commit ac4e3db

Browse files
Section 3
1 parent 3ad8afc commit ac4e3db

File tree

2 files changed

+108
-6
lines changed

2 files changed

+108
-6
lines changed

starter/03-CSS-Fundamentals/index.html

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
5+
<link href="style.css" rel="stylesheet" />
56
<title>The Basic Language of the Web: HTML</title>
67
</head>
78

@@ -24,6 +25,9 @@ <h1>📘 The Code Magazine</h1>
2425
<a href="#">Flexbox</a>
2526
<a href="#">CSS Grid</a>
2627
</nav>
28+
29+
<!--Test paragraphs
30+
<p>Test paragraphs</p> -->
2731
</header>
2832

2933
<article>
@@ -37,7 +41,9 @@ <h2>The Basic Language of the Web: HTML</h2>
3741
width="50"
3842
/>
3943

40-
<p>Posted by <strong>Laura Jones</strong> on Monday, June 21st 2027</p>
44+
<p id="author">
45+
Posted by <strong>Laura Jones</strong> on Monday, June 21st 2027
46+
</p>
4147

4248
<img
4349
src="img/post-img.jpg"
@@ -112,7 +118,7 @@ <h3>Why should you learn HTML?</h3>
112118
<aside>
113119
<h4>Related posts</h4>
114120

115-
<ul>
121+
<ul class="related">
116122
<li>
117123
<img
118124
src="img/related-1.jpg"
@@ -121,12 +127,12 @@ <h4>Related posts</h4>
121127
width="75"
122128
/>
123129
<a href="#">How to Learn Web Development</a>
124-
<p>By Jonas Schmedtmann</p>
130+
<p class="related-author">By Jonas Schmedtmann</p>
125131
</li>
126132
<li>
127133
<img src="img/related-2.jpg" alt="Lightning" width="75" heigth="75" />
128134
<a href="#">The Unknown Powers of CSS</a>
129-
<p>By Jim Dillon</p>
135+
<p class="related-author">By Jim Dillon</p>
130136
</li>
131137
<li>
132138
<img
@@ -136,11 +142,15 @@ <h4>Related posts</h4>
136142
height="75"
137143
/>
138144
<a href="#">Why JavaScript is Awesome</a>
139-
<p>By Matilda</p>
145+
<p class="related-author">By Matilda</p>
140146
</li>
141147
</ul>
142148
</aside>
143149

144-
<footer>Copyright &copy; 2027 by The Code Magazine.</footer>
150+
<footer>
151+
<p id="copyright" class="copyright text">
152+
Copyright &copy; 2027 by The Code Magazine.
153+
</p>
154+
</footer>
145155
</body>
146156
</html>

starter/03-CSS-Fundamentals/style.css

Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
h1,
2+
h2,
3+
h3,
4+
h4,
5+
p,
6+
li {
7+
font-family: sans-serif;
8+
}
9+
10+
h1,
11+
h2,
12+
h3 {
13+
color: #1098ad;
14+
}
15+
16+
h1 {
17+
font-size: 26px;
18+
text-transform: uppercase;
19+
font-style: italic;
20+
}
21+
22+
h2 {
23+
font-size: 40px;
24+
}
25+
26+
h3 {
27+
font-size: 30px;
28+
}
29+
30+
h4 {
31+
font-size: 20px;
32+
text-transform: uppercase;
33+
text-align: center;
34+
}
35+
36+
p {
37+
font-size: 22px;
38+
line-height: 1.5;
39+
}
40+
41+
li {
42+
font-size: 20px;
43+
}
44+
45+
/* footer p {
46+
font-size: 16px;
47+
} */
48+
49+
/*article header p {
50+
font-style: italic;
51+
} */
52+
53+
#author {
54+
font-style: italic;
55+
font-size: 18px;
56+
}
57+
58+
#copyright {
59+
font-size: 16px;
60+
}
61+
62+
.related-author {
63+
font-size: 18px;
64+
font-weight: bold;
65+
}
66+
67+
/* ul {
68+
list-style: none;
69+
} */
70+
71+
.related {
72+
list-style: none;
73+
}
74+
75+
/*
76+
Resolving conflicts
77+
#copyright {
78+
color: red;
79+
}
80+
81+
.copyright {
82+
color: blue;
83+
}
84+
85+
.text {
86+
color: yellow;
87+
}
88+
89+
footer p {
90+
color: green;
91+
}
92+
*/

0 commit comments

Comments
 (0)