feat: add post and tag lists to homepage

This commit is contained in:
curben 2019-10-17 06:26:26 +01:00
parent e0cb55030c
commit f92b7e0b53
No known key found for this signature in database
GPG Key ID: 5D9DB57A25D34EE3
2 changed files with 29 additions and 1 deletions

View File

@ -1 +0,0 @@
archive.ejs

View File

@ -0,0 +1,16 @@
<div class="archive-container">
<%- partial('_partial/header', {}, { cache: true }) %>
<hr class="header-hr"/>
<h2>Recent posts:</h2>
<%- list_posts({
amount: 10,
class: 'index'
}) %>
<br/>
<h2>Tags:</h2>
<%- list_tags({
amount: 0,
class: 'index',
transform: titlecase
}) %>
</div>

View File

@ -138,6 +138,10 @@ ul {
list-style: disc; list-style: disc;
} }
ul.index-list {
margin-left: unset;
}
ol { ol {
list-style: decimal; list-style: decimal;
margin-left: 1.9em; margin-left: 1.9em;
@ -286,6 +290,15 @@ blockquote {
margin-right: 1em; margin-right: 1em;
} }
/* Wrap count in brackets */
span.index-list-count:before {
content: ' (';
}
span.index-list-count:after {
content: ')';
}
.home-body { .home-body {
display: flex; display: flex;
flex-direction: column; flex-direction: column;