Skip to content

Commit

Permalink
feat(#24): custom layouts for sessions
Browse files Browse the repository at this point in the history
  • Loading branch information
sekthor committed Aug 18, 2024
1 parent d590121 commit 3cd58fe
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
12 changes: 12 additions & 0 deletions layouts/sessions/list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{{ define "main" }}
<h1>{{ .Title }}</h1>
{{ .Content }}
{{ range .Pages }}
<p><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></p>
{{ $dateMachine := .Date | time.Format "2006-01-02T15:04:05-07:00" }}
{{ $dateHuman := .Date | time.Format ":date_long" }}
<time datetime="{{ $dateMachine }}">{{ $dateHuman }}</time>
<p>{{ .Summary }}</p>
<hr/>
{{ end }}
{{ end }}
17 changes: 17 additions & 0 deletions layouts/sessions/single.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{{ define "main" }}
<h1>{{ .Title }}</h1>

{{ $dateMachine := .Date | time.Format "2006-01-02T15:04:05-07:00" }}
{{ $dateHuman := .Date | time.Format ":date_long" }}
<time datetime="{{ $dateMachine }}">{{ $dateHuman }}</time>

{{ with .GetTerms "campaigns" }}
-
{{ range .}}
<a href="{{ .RelPermalink }}" style="font-size: small;">{{ .Title }}</a>
{{ end }}
{{ end }}

{{ .Content }}
{{ partial "terms.html" (dict "taxonomy" "tags" "page" .) }}
{{ end }}

0 comments on commit 3cd58fe

Please sign in to comment.