aboutsummaryrefslogtreecommitdiff
path: root/layouts/book/summary.html
diff options
context:
space:
mode:
authorZach Berwaldt <17715430+zberwaldt@users.noreply.github.com>2023-10-20 22:58:33 -0400
committerGitHub <noreply@github.com>2023-10-20 22:58:33 -0400
commitc516745d0dc2c6a51777ef00ef116c1b26e95ec7 (patch)
treeadcce31c689d3e63ab3ea8bd36f9ac384eca4cad /layouts/book/summary.html
parentb34e09f8fe1011963934dbf40dc92f0b258592ca (diff)
parent6bfd84ae2c7aad006c3bc84cdce9aebf894cbe62 (diff)
Merge pull request #1 from zberwaldt/developHEADmaster
Develop
Diffstat (limited to 'layouts/book/summary.html')
-rw-r--r--layouts/book/summary.html29
1 files changed, 29 insertions, 0 deletions
diff --git a/layouts/book/summary.html b/layouts/book/summary.html
new file mode 100644
index 0000000..900fb87
--- /dev/null
+++ b/layouts/book/summary.html
@@ -0,0 +1,29 @@
1<section class="flex row gap-1">
2 {{ with resources.GetRemote .Params.image }}
3 {{ with .Err }}
4 {{ errorf "%s" . }}
5 {{ else }}
6 {{ $image := . }}
7 {{ $image := $image.Resize "150x" }}
8 <img
9 src="{{ $image.RelPermalink }}"
10 width="{{ $image.Width }}"
11 height="{{ $image.Height }}"
12 alt="Book cover of the book {{ .Title }}"
13 />
14 {{ end }}
15 {{ else }}
16 {{ errorf "unable to get remote resource %q" .Params.image }}
17 {{ end }}
18 <hgroup>
19 <h3 class="f3 near-black">
20 <a href="{{ .RelPermalink }}" class="link black dim">
21 {{ .Title }}
22 </a>
23 </h3>
24 <p>Rating: {{ .Params.rating }} / 5</p>
25 {{ with .Params.last_read }}
26 <p>Last Read: {{ . | time.Format ":date_full" }}</p>
27 {{ end }}
28 </hgroup>
29</section>