diff options
author | parsiya <parsiya@gmail.com> | 2018-04-22 08:36:04 +0300 |
---|---|---|
committer | parsiya <parsiya@gmail.com> | 2018-04-22 08:36:04 +0300 |
commit | 7b2be419298b015bb44a8d821dcd0f0f5d470c7c (patch) | |
tree | d7dec2b23493b9144d929db919707d3852bce321 | |
parent | 99e5d1fec4415fbd1d752ac14ffa9a59d6a1754f (diff) |
Remove redundant post template and move it to single.html
-rw-r--r-- | layouts/_default/single.html | 27 | ||||
-rw-r--r-- | layouts/post/single.html | 27 |
2 files changed, 27 insertions, 27 deletions
diff --git a/layouts/_default/single.html b/layouts/_default/single.html index e69de29..994cbd7 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -0,0 +1,27 @@ +{{ partial "header.html" . }} + +<div id="main"> + <div id="content"> + <div> + <article class="hentry" role="article"> + + {{ .Scratch.Set "isHome" false }} + {{ partial "post_header.html" . }} + + <div class="entry-content"> + <!-- insert table of contents if it is set either in the config file or in the frontmatter - frontmatter has priority --> + {{ $.Scratch.Set "pagetoc" .TableOfContents }} + <!-- the isset here is working properly becasue everything is lower case --> + {{ if or (and (isset .Params "toc") (eq .Params.toc true)) (and (not (isset .Params "toc")) (eq .Site.Params.tableOfContents true)) }} + {{ $.Scratch.Get "pagetoc" }} + {{ end }} + {{ .Content }} + </div> + {{ partial "post_footer.html" . }} + </article> + </div> + {{ partial "sidebar.html" . }} + </div> +</div> + +{{ partial "footer.html" . }} diff --git a/layouts/post/single.html b/layouts/post/single.html deleted file mode 100644 index 994cbd7..0000000 --- a/layouts/post/single.html +++ /dev/null @@ -1,27 +0,0 @@ -{{ partial "header.html" . }} - -<div id="main"> - <div id="content"> - <div> - <article class="hentry" role="article"> - - {{ .Scratch.Set "isHome" false }} - {{ partial "post_header.html" . }} - - <div class="entry-content"> - <!-- insert table of contents if it is set either in the config file or in the frontmatter - frontmatter has priority --> - {{ $.Scratch.Set "pagetoc" .TableOfContents }} - <!-- the isset here is working properly becasue everything is lower case --> - {{ if or (and (isset .Params "toc") (eq .Params.toc true)) (and (not (isset .Params "toc")) (eq .Site.Params.tableOfContents true)) }} - {{ $.Scratch.Get "pagetoc" }} - {{ end }} - {{ .Content }} - </div> - {{ partial "post_footer.html" . }} - </article> - </div> - {{ partial "sidebar.html" . }} - </div> -</div> - -{{ partial "footer.html" . }} |