Skip to content

Commit 61e9e9e

Browse files
committed
Use HTML list instead of <div>s
1 parent 0f9f9ab commit 61e9e9e

File tree

3 files changed

+21
-12
lines changed

3 files changed

+21
-12
lines changed

blog.html

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,11 @@
33
---
44
<h2>Posts</h2>
55

6-
{% for post in site.categories.blog %}
7-
<div class="post">
8-
<div class="post-date">{{ post.date | date: "%b %-d, %Y" }}</div>
9-
<a class="post-link" href="{{ post.url | prepend: site.baseurl }}">{{ post.title }}</a>
10-
</div>
11-
{% endfor %}
6+
<ul class="post-list">
7+
{% for post in site.categories.blog %}
8+
<li class="post">
9+
<div class="post-date">{{ post.date | date: "%b %-d, %Y" }}</div>
10+
<a class="post-link" href="{{ post.url | prepend: site.baseurl }}">{{ post.title }}</a>
11+
</li>
12+
{% endfor %}
13+
</ul>

css/main.css

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,11 @@ a.source:hover {
147147
list-style: none;
148148
}
149149

150+
.post-list {
151+
margin: 0;
152+
padding: 0;
153+
list-style-type: none;
154+
}
150155

151156
.post {
152157
margin: 0 0 1.5rem 0;

thisweek.html

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,11 @@
33
---
44
<h2>This Week In rust-analyzer</h2>
55

6-
{% for post in site.categories.thisweek %}
7-
<div class="post">
8-
<div class="post-date">{{ post.date | date: "%b %-d, %Y" }}</div>
9-
<a class="post-link" href="{{ post.url | prepend: site.baseurl }}">{{ post.title }}</a>
10-
</div>
11-
{% endfor %}
6+
<ul class="post-list">
7+
{% for post in site.categories.thisweek %}
8+
<li class="post">
9+
<div class="post-date">{{ post.date | date: "%b %-d, %Y" }}</div>
10+
<a class="post-link" href="{{ post.url | prepend: site.baseurl }}">{{ post.title }}</a>
11+
</li>
12+
{% endfor %}
13+
</ul>

0 commit comments

Comments
 (0)