Added list summaries configuration, tweaked social icons margin on mobile

This commit is contained in:
Francesco 2024-04-30 22:12:00 +02:00
parent b372fcf6f2
commit 0a3f759770
4 changed files with 28 additions and 11 deletions

View file

@ -154,6 +154,8 @@ homeCollection = 'posts'
# Pagination size across all website, this is the same for homepage and single list page
paginationSize = 100
# Display summaries under post list entries
listSummaries = false
# Social icons
[[params.social]]

View file

@ -151,10 +151,6 @@ footer a {
/* Posts list */
.post-list-container {
margin-bottom: 2rem;
}
.post-line {
margin-bottom: .5rem;
display: flex;
@ -166,18 +162,27 @@ footer a {
margin-bottom: 0rem;
}
.post-date {
.line-date {
font-size: small;
font-family: "Monaspace";
width: 110px;
min-width: 110px;
max-width: 110px;
text-align: right;
padding-right: 1rem;
margin-top: 0rem;
margin-bottom: 0rem;
}
.post-title {
.line-title {
margin: 0;
}
.line-summary {
font-size: small;
margin-top: .2rem !important;
font-style: italic;
}
.pagination {
display: flex;
align-items: center;
@ -209,7 +214,7 @@ footer a {
.social-icons {
padding: 12px 0;
margin-bottom: 3rem;
margin-bottom: var(--social-icons-bottom-margin)
}
.social-icons a {

View file

@ -29,10 +29,13 @@
--toc-margin-top: 2rem;
--toc-margin-bottom: 3rem;
/* code */
/* Code */
--code-padding: 1.5rem;
--code-border-radius: 10px;
/* Social section */
--social-icons-bottom-margin: 3rem;
/* Footer */
--footer-height: 3rem;
@ -61,5 +64,6 @@
@media screen and (max-width: 640px) {
:root {
--header-top-gap: 1rem;
--social-icons-bottom-margin: 0rem;
}
}

View file

@ -1,4 +1,10 @@
<div class="post-line">
<p class="post-date">{{ .Date.Format "2 Jan 2006" }} </p>
<p class="post-title"> <a href="{{ .RelPermalink }}">{{ .Title }}</a></p>
<p class="line-date">{{ .Date.Format "2 Jan 2006" }} </p>
<div>
<p class="line-title"> <a href="{{ .RelPermalink }}">{{ .Title }}</a></p>
{{ if .Site.Params.listSummaries }}
<p class="line-summary"> {{ .Summary }} </p>
{{ end }}
</div>
</div>