Skip to content

Commit 21d7708

Browse files
author
lintsang
committed
Add breathing line in after every element in css
1 parent e366ccd commit 21d7708

1 file changed

Lines changed: 11 additions & 5 deletions

File tree

Wireframe/style.css

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,49 +24,53 @@ As well as useful links to learn more */
2424
--line: 1px solid;
2525
--container: 1280px;
2626
}
27+
2728
/* ====== Base Elements ======
2829
General rules for basic HTML elements in any context */
29-
30-
body {
30+
body {
3131
background: var(--paper);
3232
color: var(--ink);
3333
font: var(--font);
3434
text-align: center;
3535
display: grid;
36-
3736
}
37+
3838
a {
3939
padding: var(--space);
4040
border: var(--line);
4141
max-width: fit-content;
4242
}
43+
4344
img,
4445
svg {
4546
width: 100%;
4647
object-fit: cover;
4748
}
49+
4850
p {
4951
padding: 0 0 30px 0;
5052
}
53+
5154
.image-wrapper img {
5255
width: 100%;
5356
/* aspect ratio for image */
5457
aspect-ratio: 16 / 9;
5558
}
5659

57-
5860
/* ====== Site Layout ======
5961
Setting the overall rules for page regions
6062
https://www.w3.org/WAI/tutorials/page-structure/regions/
6163
*/
62-
header, main{
64+
header, main {
6365
width: 80%;
6466
margin-inline: auto;
6567
}
68+
6669
main {
6770
max-width: var(--container);
6871
margin: 0 auto calc(var(--space) * 4) auto;
6972
}
73+
7074
footer {
7175
width: 100%;
7276
position: relative;
@@ -75,6 +79,7 @@ footer {
7579
font-size: 0.8rem;
7680
padding: 60px 120px;
7781
}
82+
7883
/* ====== Articles Grid Layout ====
7984
Setting the rules for how articles are placed in the main element.
8085
Inspect this in Devtools and click the "grid" button in the Elements view
@@ -90,6 +95,7 @@ main {
9095
grid-column: span 2;
9196
}
9297
}
98+
9399
/* ====== Article Layout ======
94100
Setting the rules for how elements are placed in the article.
95101
Now laying out just the INSIDE of the repeated card/article design.

0 commit comments

Comments
 (0)