Update styles and set up genres list page

This commit is contained in:
Campbell Alden 2022-08-31 17:57:49 +09:00
parent 9163b9dbbb
commit 870c36de1f
4 changed files with 35 additions and 20 deletions

View file

@ -1,17 +0,0 @@
{{ define "main" }}
<article>
<header>
<h1>{{.Title}}</h1>
</header>
<!-- "{{.Content}}" pulls from the markdown content of the corresponding _index.md -->
{{.Content}}
</article>
<ul>
<!-- Ranges through content/posts/*.md -->
{{ range .Pages }}
<li>
<a href="{{.Permalink}}">{{.Date.Format "2006-01-02"}} | {{.Title}}</a>
</li>
{{ end }}
</ul>
{{ end }}

View file

@ -0,0 +1,21 @@
{{ define "main"}}
<section>
<header style="margin-bottom: 30px;">
<h1>{{.Title}}</h1>
</header>
{{range .Pages }}
<section>
<header class="cluster spacing:between p1" style="align-items: flex-end;">
<h2>{{.Data.Term}}</h2>
<a href="{{ .Data.Term | urlize }}" class="button button:large">See more</a>
</header>
<div class="carasol">
{{range first 25 .Data.Pages | shuffle }}
{{ .Render "summary" }}
{{end}}
</div>
</section>
{{end}}
</section>
{{ end }}

View file

@ -23,10 +23,12 @@
.card:hover .card-content { .card:hover .card-content {
flex-basis: 50%; flex-basis: 50%;
transition-delay: 0ms;
padding-top: 10px; padding-top: 10px;
} }
.card:hover .card-image { .card:hover .card-image {
flex-basis: 50%; flex-basis: 50%;
transition-delay: 0ms;
} }
.card-content { .card-content {
@ -35,11 +37,13 @@
flex-direction: column; flex-direction: column;
gap: 10px; gap: 10px;
justify-content: space-between; justify-content: space-between;
transition: flex-basis 250ms ease-out; transition: all 250ms ease-out;
transition-delay: 250ms;
} }
.card-image { .card-image {
transition: flex-basis 250ms ease-out; transition: all 250ms ease-out;
transition-delay: 250ms;
flex-grow: 1; flex-grow: 1;
flex-basis: 100%; flex-basis: 100%;
object-fit: cover; object-fit: cover;

View file

@ -90,7 +90,7 @@ main {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
max-width: 900px; max-width: 930px;
} }
.title, h1 { .title, h1 {
@ -284,3 +284,10 @@ a:hover {
.http-header { .http-header {
class="home-page-header" margin-top: 10vh; class="home-page-header" margin-top: 10vh;
} }
.carasol {
display: flex;
overflow: auto;
gap: 10px;
padding-bottom: 20px;
}