first commit
This commit is contained in:
20
layouts/_default/list.html
Normal file
20
layouts/_default/list.html
Normal file
@@ -0,0 +1,20 @@
|
||||
<div class="posts-list">
|
||||
<h1>{{ .Title }}</h1>
|
||||
|
||||
{{ range .Pages }}
|
||||
<article class="post-preview">
|
||||
<h2><a href="{{ .RelPermalink }}">{{ .Title }}</a></h2>
|
||||
<div class="post-meta">
|
||||
<time>{{ .Date.Format "Jan 2, 2006" }}</time>
|
||||
{{ if .Params.author }}
|
||||
<span>{{ .Params.author.name }}</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ if .Params.excerpt }}
|
||||
<p class="post-excerpt">{{ .Params.excerpt }}</p>
|
||||
{{ end }}
|
||||
<a href="{{ .RelPermalink }}" class="read-more">Read more →</a>
|
||||
</article>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
35
layouts/_default/single.html
Normal file
35
layouts/_default/single.html
Normal file
@@ -0,0 +1,35 @@
|
||||
{{ define "main" }}
|
||||
<article class="post">
|
||||
<header class="post-header">
|
||||
<h1 class="post-title">{{ .Title }}</h1>
|
||||
<div class="post-meta">
|
||||
<time datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 2, 2006" }}</time>
|
||||
{{ if .Params.author }}
|
||||
<span class="post-author">{{ .Params.author.name }}</span>
|
||||
{{ end }}
|
||||
{{ if .Params.categories }}
|
||||
<div class="post-categories">
|
||||
{{ range .Params.categories }}
|
||||
<a href="/categories/{{ .slug }}" class="category">{{ .name }}</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ if .Params.featured_image }}
|
||||
<img src="{{ .Params.featured_image }}" alt="{{ .Title }}" class="featured-image">
|
||||
{{ end }}
|
||||
</header>
|
||||
|
||||
<div class="post-content">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
|
||||
{{ if .Params.tags }}
|
||||
<div class="post-tags">
|
||||
{{ range .Params.tags }}
|
||||
<a href="/tags/{{ .slug }}" class="tag">#{{ .name }}</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
||||
Reference in New Issue
Block a user