_index.md's content is shown at list page

This commit is contained in:
leafee98 2022-05-18 19:45:04 +08:00
parent 23e6e10f43
commit 836128c866
5 changed files with 96 additions and 74 deletions

View file

@ -8,3 +8,5 @@ draft: false
---
<!--more-->
*There are some short articles.*

View file

@ -1,5 +1,10 @@
{{ define "main" }}
<div>
{{ if trim .Content " \n" }}
<div class="content archive-hint">{{ .Content }}</div>
{{ end }}
<section id="archive">
{{ range .Data.Pages.GroupByDate "2006" }}
<div class="group">
@ -29,5 +34,6 @@
{{ end }}
</section>
</div>
{{ end }}

View file

@ -1,5 +1,10 @@
{{ define "main" }}
<div>
{{ if trim .Content " \n" }}
<div class="content archive-hint">{{ .Content }}</div>
{{ end }}
<section id="archive">
{{ range .Data.Pages.GroupByDate "2006" }}
<div class="group">
@ -29,5 +34,6 @@
{{ end }}
</section>
</div>
{{ end }}

View file

@ -1,5 +1,5 @@
<header class="header-wrapper">
<div class="header max-wrapper">
<div class="header">
<a class="site-title" href="{{ .Site.BaseURL }}">{{ .Site.Title }}</a>
<ul class="menu">

View file

@ -120,12 +120,6 @@ body {
margin-bottom: 0;
}
.max-wrapper {
width: 100%;
height: 100%;
padding: 0;
margin: 0;
}
/********** set up break point **********/
@ -142,13 +136,13 @@ body {
.header-wrapper, .footer { width: 100vw;}
.main-wrapper { width: calc(100vw - 2 * var(--len-3));}
/************************/
/* set up header layout */
/************************/
.header {
padding: var(--len-3);
width: 100%;
}
/* place title and menus horizonally */
@ -265,7 +259,6 @@ body {
color: var(--color-fav-2);
}
/**********************************/
/* set up home page's list layout */
/**********************************/
@ -505,9 +498,9 @@ body {
overflow-x: auto;
}
/********************************/
/* setup taxonomies page layout */
/********************************/
/**************************/
/* setup list page layout */
/**************************/
#archive {
padding-left: var(--len-3);
@ -642,3 +635,18 @@ body {
color: var(--color-black-3)
}
/**********/
/** misc **/
/**********/
.archive-hint {
padding-left: var(--len-4);
color: var(--color-fav-1);
}
.max-wrapper {
width: 100%;
height: 100%;
padding: 0;
margin: 0;
}