aboutsummaryrefslogtreecommitdiffstats
path: root/layouts/project/single.html
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/project/single.html')
-rw-r--r--layouts/project/single.html50
1 files changed, 50 insertions, 0 deletions
diff --git a/layouts/project/single.html b/layouts/project/single.html
new file mode 100644
index 0000000..eacb6d1
--- /dev/null
+++ b/layouts/project/single.html
@@ -0,0 +1,50 @@
+{{- define "main" -}}
+ <header class="mw7 center">
+ <h2 class="baskerville f2 lh-title mv3 ph1">
+ {{ .Title }}
+ </h2>
+
+ {{ with .Params.subtitle }}
+ <h3 class="f3 baskerville mv3 pa1">{{ . }}</h3>
+ {{ end }}
+
+ {{ partial "meta_links.html" . }}
+ {{ partial "leading_image.html" . }}
+ </header>
+ <div class="main-content mw7 center lh-copy f5 f4-ns ph1">
+ {{ .Content }}
+ </div>
+
+ <div class="mw7 center ph1">
+ {{ $page := . }}
+ {{ $project := .File.ContentBaseName }}
+
+ {{ $items := where (where site.RegularPages "Type" "post") ".Params.projects" "intersect" (slice $project) }}
+ {{ $count := len $items }}
+ {{ if ge $count 1 }}
+ <h2 class="f2 fw3 ma0">Related Posts</h2>
+ {{ range $index, $item := $items }}
+ {{ partial "post.html" . }}
+ {{ end }}
+ {{ end }}
+
+ {{ $items := where (where site.RegularPages "Type" "publication") ".Params.projects" "intersect" (slice $project) }}
+ {{ $pubs_len := len $items }}
+ {{ if ge $pubs_len 1 }}
+ <h2 class="f2 fw3 ma0">Related Publications</h2>
+ {{ range $index, $item := $items }}
+ {{ partial "post.html" . }}
+ {{ end }}
+ {{ end }}
+
+ {{ $items := where (where site.RegularPages "Type" "event") ".Params.projects" "intersect" (slice $project) }}
+ {{ $talks_len := len $items }}
+ {{ if ge $talks_len 1 }}
+ <h2 class="f2 fw3 ma0">Related Talks</h2>
+ {{ range $index, $item := $items }}
+ {{ partial "post.html" . }}
+ {{ end }}
+ {{ end }}
+ {{ partial "post_pager" . }}
+ </div>
+{{- end -}}