Styled the categories on the site

This commit is contained in:
Leon Mika 2026-03-22 10:28:33 +11:00
parent f45bdcd83c
commit d9aec4af2c
16 changed files with 176 additions and 59 deletions

View file

@ -5,7 +5,7 @@
</div>
</div>
{{ range .categories }}
{{ if .categories }}
<table class="table">
<thead>
<tr>
@ -15,11 +15,13 @@
</tr>
</thead>
<tbody>
<tr>
<td><a href="/sites/{{ $.site.ID }}/categories/{{ .ID }}">{{ .Name }}</a></td>
<td><code>{{ .Slug }}</code></td>
<td>{{ .PostCount }}</td>
</tr>
{{ range .categories }}
<tr>
<td><a href="/sites/{{ $.site.ID }}/categories/{{ .ID }}">{{ .Name }}</a></td>
<td><code>{{ .Slug }}</code></td>
<td>{{ .PostCount }}</td>
</tr>
{{ end }}
</tbody>
</table>
{{ else }}