Initial commit
This commit is contained in:
14
layouts/_default/baseof.html
Normal file
14
layouts/_default/baseof.html
Normal file
@@ -0,0 +1,14 @@
|
||||
<!DOCTYPE html>
|
||||
<!-- Default base template. Other templates define the "main" portion in this template -->
|
||||
<html lang="{{ $.Site.LanguageCode | default "en" }}">
|
||||
{{ partial "head.html" . }}
|
||||
<body>
|
||||
{{ partial "nav.html" . }}
|
||||
<div id="content" class="content-container">
|
||||
{{ block "main" . }}
|
||||
{{ end }}
|
||||
{{ partial "math.html" . }}
|
||||
</div>
|
||||
{{ partial "footer-mobile.html" . }}
|
||||
</body>
|
||||
</html>
|
30
layouts/_default/section.html
Normal file
30
layouts/_default/section.html
Normal file
@@ -0,0 +1,30 @@
|
||||
<!-- This page is the same as the Archives page -->
|
||||
{{ define "main" }}
|
||||
<!-- All of the site's posts grouped by year -->
|
||||
<h1>
|
||||
Archives
|
||||
</h1>
|
||||
<div>
|
||||
<!-- Group all the post pages from the same year -->
|
||||
{{ $pages := where site.RegularPages "Type" "in" site.Params.mainSections }}
|
||||
{{ range ($pages.GroupByDate "2006") }}
|
||||
<h3>{{ .Key }}</h3> <!-- Display the year -->
|
||||
|
||||
<ul class="archives-list">
|
||||
|
||||
{{ range (.Pages) }}
|
||||
|
||||
<li class="archives-list-item">
|
||||
<span class="archives-list-item-date">{{ .PublishDate.Format "Jan 2" }}</span>
|
||||
<span>
|
||||
<a href="{{ .RelPermalink }}">{{ .Title }}</a>
|
||||
</span>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<div class="page-footer"></div>
|
||||
|
||||
{{ end }}
|
23
layouts/_default/single.html
Normal file
23
layouts/_default/single.html
Normal file
@@ -0,0 +1,23 @@
|
||||
{{ define "main" }}
|
||||
<h1 class="post-title">{{ .Title }}</h1>
|
||||
<time>{{ .Date.Format "January 2, 2006" }}</time>
|
||||
<div>
|
||||
<p>
|
||||
{{ .Content }}
|
||||
</p>
|
||||
</div>
|
||||
{{ template "_internal/disqus.html" . }}
|
||||
|
||||
<div class="page-footer">
|
||||
{{ $taxonomy := "tags" }}
|
||||
{{ with .Param $taxonomy }}
|
||||
<hr class="footer-divider">
|
||||
{{ range $index, $tag := . }}
|
||||
{{ with $.Site.GetPage (printf "/%s/%s" $taxonomy $tag) }}
|
||||
<a class="tag" href="{{ .Permalink }}">#{{ $tag | urlize }}</a>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{end}}
|
24
layouts/_default/tag.html
Normal file
24
layouts/_default/tag.html
Normal file
@@ -0,0 +1,24 @@
|
||||
{{ define "main" }}
|
||||
<!-- Page that displays after clicking on a post's tag -->
|
||||
<h1>Tagged "{{ .Data.Term }}"</h1>
|
||||
{{range .Pages}}
|
||||
|
||||
<!-- Display the posts with the tag -->
|
||||
<article>
|
||||
<h2>
|
||||
<a href="{{ .Permalink }}">
|
||||
{{ .Title }}
|
||||
</a>
|
||||
</h2>
|
||||
<div>
|
||||
<p>
|
||||
{{ .Summary }}
|
||||
</p>
|
||||
</div>
|
||||
<div class="post-footer">
|
||||
<time>{{ .Date.Format "January 2, 2006" }}</time>
|
||||
</div>
|
||||
</article>
|
||||
{{ end }}
|
||||
|
||||
{{ end }}
|
Reference in New Issue
Block a user