diff options
author | monkeyWzr <monkeywzr@gmail.com> | 2020-07-10 20:33:42 +0300 |
---|---|---|
committer | monkeyWzr <monkeywzr@gmail.com> | 2020-07-10 20:33:42 +0300 |
commit | 0a0c2466f7110e956f1c42bfbed1ea0a412323ca (patch) | |
tree | d4a68a73b3cf26a96fe8b1fa68631b57296b4d54 /layouts/posts |
first commit
Diffstat (limited to 'layouts/posts')
-rw-r--r-- | layouts/posts/single.html | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/layouts/posts/single.html b/layouts/posts/single.html new file mode 100644 index 0000000..9a2a6cf --- /dev/null +++ b/layouts/posts/single.html @@ -0,0 +1,60 @@ +{{ define "main" }} +<article class="post" itemscope itemtype="http://schema.org/BlogPosting"> + <header> + <h1 class="posttitle" itemprop="name headline"> + {{ .Title }} + </h1> + <div class="meta"> + {{ if (or (isset .Site "author") (isset .Site "title"))}} + <span class="author" itemprop="author" itemscope itemtype="http://schema.org/Person"> + <span itemprop="name"> + {{ if isset .Site "author" }} + {{ .Site.Author }} + {{ else if isset .Site "title" }} + {{ .Site.Title }} + {{ end }} + </span> + </span> + {{ end }} + <div class="postdate"> + <time datetime="{{ .Date }}" itemprop="datePublished">{{ .Date.Format .Site.Params.dateFormat }}</time> + {{ if (and .Site.Params.show_updated (ne .Lastmod .Date)) }} + (Updated: <time datetime="{{ .Lastmod }}" itemprop="dateModified">{{ .Lastmod.Format .Site.Params.dateFormat }}</time>) + {{ end }} + </div> + {{ if gt .Params.categories 0 }} + <div class="article-category"> + <i class="fas fa-archive"></i> + {{ range $index, $value := .Params.categories }} + {{ if gt $index 1 }} {{ print ", " }} {{ end }} + <a class="category-link" href="{{ "/categories/" | relLangURL }}{{ $value | urlize }}">{{ $value }}</a> + {{ end }} + </div> + {{ end }} + {{ if gt .Params.tags 0 }} + <div class="article-tag"> + <i class="fas fa-tag"></i> + {{ range $index, $value := .Params.tags }} + {{ if gt $index 1 }} {{ print ", " }} {{ end }} + <a class="tag-link" href="{{ "/tags/" | relLangURL }}{{ $value | urlize }}" rel="tag">{{ $value }}</a> + {{ end }} + </div> + {{ end }} + </div> + </header> + +{{ with .Resources.ByType "image" }} + <div class="article-gallery"> + {{ range $index, $value := . }} + <a class="gallery-item" href="{{ .RelPermalink }}" rel="gallery_{{ $index }}"> + <img src="{{ .RelPermalink }}" itemprop="image" /> + </a> + {{ end }} + </div> +{{ end }} + <div class="content" itemprop="articleBody"> + {{ .Content}} + </div> +</article> +<!-- TODO: Ccomments --> +{{ end }}
\ No newline at end of file |