Skip to content

Commit d93c40e

Browse files
committed
Combined some of css rules into combined selectors, a list and an descendant. In order to not repeat common css rules over and over.
1 parent a109e66 commit d93c40e

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed

starter/03-CSS-Fundamentals/index.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,8 @@ <h4>Related posts</h4>
150150
</ul>
151151
</aside>
152152

153-
<footer>Copyright &copy; 2027 by The Code Magazine.</footer>
153+
<footer>
154+
<p>Copyright &copy; 2027 by The Code Magazine.</p>
155+
</footer>
154156
</body>
155157
</html>

starter/03-CSS-Fundamentals/style.css

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
1+
h1,
2+
h2,
3+
h3,
4+
h4,
5+
p,
6+
li {
7+
font-family: sans-serif;
8+
}
9+
110
h1 {
211
font-size: 26px;
3-
font-family: sans-serif;
412
text-transform: uppercase;
513
font-style: italic;
614
}
@@ -32,3 +40,13 @@ li {
3240
font-family: sans-serif;
3341
font-size: 20px;
3442
}
43+
44+
/* css descendants are actually a bad practice */
45+
footer p {
46+
font-size: 16px;
47+
}
48+
49+
/* css descendants are actually a bad practice */
50+
article header p {
51+
font-style: italic;
52+
}

0 commit comments

Comments
 (0)