Skip to content

Commit f42b29b

Browse files
committed
Applied some different box types, either inline / block / inline-block, to some elements.
1 parent eb73f87 commit f42b29b

File tree

1 file changed

+25
-2
lines changed

1 file changed

+25
-2
lines changed

starter/03-CSS-Fundamentals/style.css

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
padding: 0;
55
}
66

7-
/* Inheritance example */
7+
/* PAGE SECTIONS */
88
body {
99
color: #444;
1010
font-family: sans-serif;
@@ -25,7 +25,7 @@ body {
2525
padding-right: 40px; */
2626
padding: 20px 40px;
2727
margin-bottom: 60px;
28-
height: 80px;
28+
/* height: 80px; */
2929
}
3030

3131
/* Inheritance example */
@@ -49,6 +49,7 @@ aside {
4949
width: 500px;
5050
}
5151

52+
/* SMALLER ELEMENTS */
5253
h1,
5354
h2,
5455
h3 {
@@ -82,6 +83,9 @@ p {
8283
font-size: 22px;
8384
line-height: 1.5;
8485
margin-bottom: 15px;
86+
87+
/* Block to Inline level Elements Behavior Demo */
88+
/* display: inline; */
8589
}
8690

8791
ul,
@@ -93,6 +97,9 @@ ol {
9397
li {
9498
font-size: 20px;
9599
margin-bottom: 10px;
100+
101+
/* Block to Inline level Elements Behavior Demo */
102+
/* display: inline; */
96103
}
97104

98105
li:last-child {
@@ -193,6 +200,22 @@ a:active {
193200
height: auto;
194201
}
195202

203+
nav a:link {
204+
/* Inline To Block level Elements Behavior Demo */
205+
/* background-color: orangered;
206+
margin: 20px;
207+
padding: 20px;
208+
display: block; */
209+
210+
margin-right: 30px;
211+
margin-top: 10px;
212+
display: inline-block;
213+
}
214+
215+
nav a:link:last-child {
216+
margin-right: 0;
217+
}
218+
196219
/* Resolving conflicts */
197220
#copyright {
198221
color: yellow;

0 commit comments

Comments
 (0)