fix feed layout

This commit is contained in:
anna 2021-02-11 19:12:20 +01:00
parent d57858f3df
commit 550fe42cfb
Signed by: fef
GPG key ID: EC22E476DC2D3D84
3 changed files with 34 additions and 14 deletions

View file

@ -2,9 +2,10 @@
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>{{ site.title }}</title>
<link rel="stylesheet" href="{{ 'assets/css/main.css' | relative_url }}"> <link rel="stylesheet" href="{{ 'assets/css/main.css' | relative_url }}">
<link rel="stylesheet" href="{{ 'assets/fonts/oleoscript.css' | relative_url }}"> <link rel="stylesheet" href="{{ 'assets/fonts/oleoscript.css' | relative_url }}">
<link rel="alternate" type="application/atom+xml" title="Atom feed" href="{{ '/feed.xml' | relative_url }}"> <link rel="alternate" type="application/atom+xml" title="Atom feed" href="{{ '/feed.xml' | relative_url }}">
{% seo %} {% seo %}
@ -30,7 +31,7 @@
<div><p>{{ site.description }}</p></div> <div><p>{{ site.description }}</p></div>
<div> <div>
<p> <p>
Email: <a href="mailto:owo@fef.moe">owo@fef.moe</a> Email: <a href="mailto:{{ site.author.email }}">{{ site.author.email }}</a>
<br> <br>
Fediverse: Fediverse:

View file

@ -17,9 +17,6 @@ body {
footer { footer {
padding: 20px 0; padding: 20px 0;
}
footer {
border-top: thin solid $color-primary; border-top: thin solid $color-primary;
} }
@ -34,6 +31,30 @@ header h1 {
font-family: "OleoScript", sans-serif; font-family: "OleoScript", sans-serif;
} }
main {
max-width: $content-width;
margin: 0 auto;
padding: 0 20px;
}
article.feed-item {
margin: 0 0 20px;
padding: 0 0 20px;
border-bottom: thin solid rgba(255, 255, 255, 0.2);
:last-child {
margin-bottom: 0;
}
}
article.feed-item:first-child {
margin-top: 40px;
}
article.feed-item:last-child {
border-bottom: 0;
}
a { a {
color: $color-primary; color: $color-primary;
} }

View file

@ -2,12 +2,10 @@
layout: default layout: default
--- ---
<ul id="feed"> {% for post in site.posts %}
{% for post in site.posts %} <article class="feed-item">
<li> <small class="date">{{ post.date | date: "%Y-%m-%d" }}</small>
<small class="date">{{ post.date | date: "%Y年%m月%d日" }}</small> <h3><a href="{{ post.url }}">{{ post.title }}</a></h3>
<h3><a href="{{ post.url }}">{{ post.title }}</a></h3> {{ post.excerpt }}
{{ post.excerpt }} </article>
</li> {% endfor %}
{% endfor %}
</ul>