Adding some colorful borders to each post

This commit is contained in:
shockrah committed 2023-09-24 15:42:46 -07:00
1 parent 88bf31076d
commit 4a64e470ec
2 files changed
+6 -3

No files matched your search

@@ -1,6 +1,9 @@
{{ define "main" }}
{{ range .Pages.ByDate.Reverse }}
<div class="card">
{{ $colors := slice "cyan" "yellow" "pink"}}
{{ $opts := len $colors }}
{{ range $i, $page := .Pages.ByDate.Reverse }}
{{ $opt := mod $i $opts }}
<div class="card" style="border-color: {{ index $colors $opt }}">
<a href="{{ anchorize .Page.Name }}">
<h5 class="card-header postcard card-title">{{ .Title }}</h5>
</a>