Skip to content

Commit 6ef5a38

Browse files
committed
Adding Featured Posts heading
1 parent a46ef6e commit 6ef5a38

File tree

3 files changed

+35
-39
lines changed

3 files changed

+35
-39
lines changed

_sass/_content.scss

+18-20
Original file line numberDiff line numberDiff line change
@@ -198,25 +198,29 @@ blockquote > p {
198198
width: 60px;
199199
}
200200

201-
.post-feed .post {
202-
border-bottom: 1px solid $gray-lighter;
203-
}
201+
.post-feed {
202+
.post-header {
203+
margin-bottom: 0.83333em;
204+
}
204205

205-
.post-feed .post-header {
206-
margin-bottom: 0.83333em;
207-
}
206+
.post {
207+
border-bottom: 1px solid $gray-lighter;
208+
}
208209

209-
.post-feed .post-content {
210-
font-size: 0.88889rem;
211-
margin-bottom: 1.66667em;
210+
.post-content {
211+
font-size: 0.88889rem;
212+
margin-bottom: 1.66667em;
213+
}
212214
}
213215

214-
.read-next .post-title {
215-
font-size: 1.33333rem;
216-
}
216+
.read-next {
217+
.post-title {
218+
font-size: 1.33333rem;
219+
}
217220

218-
.read-next .post-meta {
219-
margin-bottom: 0.5em;
221+
.post-meta {
222+
margin-bottom: 0.5em;
223+
}
220224
}
221225

222226
.tag-top {
@@ -257,7 +261,6 @@ ul.archive-posts-list {
257261
margin-bottom: 0.5556em
258262
}
259263
}
260-
261264
/* Archives */
262265
.page-header {
263266
margin-bottom: 1.66667em;
@@ -276,7 +279,6 @@ ul.archive-posts-list {
276279
margin: 0.25em 0 0;
277280
text-transform: uppercase;
278281
}
279-
280282
/* Hero section */
281283
.hero {
282284
margin-bottom: 2.5em;
@@ -299,7 +301,6 @@ ul.archive-posts-list {
299301
margin: 0;
300302
}
301303

302-
/* Featured posts */
303304
.featured-posts {
304305
display: -ms-flexbox;
305306
display: -webkit-flex;
@@ -342,7 +343,6 @@ ul.archive-posts-list {
342343
}
343344
}
344345
}
345-
346346
/* Projects */
347347
.project {
348348

@@ -410,7 +410,6 @@ ul.archive-posts-list {
410410
margin-bottom: .4em;
411411
}
412412
}
413-
414413
/* Products */
415414
.featured-products {
416415
display: -ms-flexbox;
@@ -458,7 +457,6 @@ ul.archive-posts-list {
458457
width: 63%;
459458
}
460459
}
461-
462460
/**
463461
* 4.2 Pagination
464462
* ----------------------------------------------------------------------------

_sass/_media-queries.scss

-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
.site-content {
99
margin-left: 30vw;
1010
padding-bottom: 3.33333em;
11-
padding-top: 3.33333em;
1211
}
1312

1413
.site-header {

index.html

+17-18
Original file line numberDiff line numberDiff line change
@@ -5,31 +5,30 @@
55

66
<main id="main" class="site-main">
77

8-
{% if page.url == "/" %}
9-
<!-- Featured-->
10-
<div id="featured-posts" class="featured-posts">
11-
{% for post in site.posts %}
12-
{% if post.featured == true %}
13-
{% include featuredbox.html %}
14-
{% endif %}
15-
{% endfor %}
16-
</div>
17-
18-
{% endif%}
8+
{% if page.url == "/" %}
9+
<!-- Featured-->
10+
<div class="post-feed-title">Featured</div>
11+
<div id="featured-posts" class="featured-posts">
12+
{% for post in site.posts %}
13+
{% if post.featured == true %}
14+
{% include featuredbox.html %}
15+
{% endif %}
16+
{% endfor %}
17+
</div>
18+
{% endif%}
1919

20-
<!-- Posts Index -->
21-
<div class="post-feed inner">
20+
<!-- Posts Index -->
2221
{% if page.url == "/" %}
2322
<div class="post-feed-title">Latest</div>
2423
{% endif %}
25-
<div class="post-feed inner-wide">
24+
<div class="post-feed inner">
2625
{% for post in paginator.posts %}
27-
{% include postbox.html %}
26+
{% include postbox.html %}
2827
{% endfor %}
2928
</div>
30-
</div>
31-
<!-- Pagination-->
32-
{% include pagination.html %}
29+
30+
<!-- Pagination-->
31+
{% include pagination.html %}
3332
</main>
3433

3534

0 commit comments

Comments
 (0)