mirror of
https://github.com/thegeeklab/hugo-geekblog.git
synced 2024-11-25 06:20:40 +00:00
add basic post metadata to posts single view
This commit is contained in:
parent
206fe0cef9
commit
c146f130d7
@ -4,3 +4,4 @@
|
|||||||
the date on updated posts will be prefixed with `Updated on` string
|
the date on updated posts will be prefixed with `Updated on` string
|
||||||
modifications from the same day are ignored
|
modifications from the same day are ignored
|
||||||
- add read time indicator
|
- add read time indicator
|
||||||
|
- add basic post metadata to posts single view
|
||||||
|
@ -16,6 +16,24 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<h1>{{ partial "title" . }}</h1>
|
<h1>{{ partial "title" . }}</h1>
|
||||||
|
<div class="gblog-post__meta">
|
||||||
|
<span class="no-wrap">
|
||||||
|
<svg class="icon date"><use xlink:href="#date"></use></svg>
|
||||||
|
<span class="gblog-post__tag">
|
||||||
|
<time datetime="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" | safeHTML }}">
|
||||||
|
{{ if ne (.Lastmod.Format "2006-01-02") (.Date.Format "2006-01-02") }}
|
||||||
|
Updated on
|
||||||
|
{{ end }}
|
||||||
|
{{ .Lastmod.Format "Jan 2, 2006" }}
|
||||||
|
</time>
|
||||||
|
</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span class="no-wrap">
|
||||||
|
<svg class="icon timer"><use xlink:href="#timer"></use></svg>
|
||||||
|
<span class="gblog-post__tag">{{ .ReadingTime }} min</span>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
<section class="gblog-markdown">
|
<section class="gblog-markdown">
|
||||||
|
@ -288,6 +288,14 @@ img {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&__meta {
|
||||||
|
padding-bottom: $padding-16;
|
||||||
|
|
||||||
|
.icon {
|
||||||
|
font-size: 1.2em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
&__figure {
|
&__figure {
|
||||||
padding: $padding-4 $padding-4 0 $padding-4;
|
padding: $padding-4 $padding-4 0 $padding-4;
|
||||||
margin: $padding-16 0;
|
margin: $padding-16 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user