feat: limit homepage latest posts to 4, fix total post count in CTA
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+3
-3
@@ -117,14 +117,14 @@
|
||||
</div>
|
||||
|
||||
<div class="relative z-10 grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-5">
|
||||
{{- range first 8 $latest -}}
|
||||
{{- range first 4 $latest -}}
|
||||
{{- partial "post-card.html" . -}}
|
||||
{{- end -}}
|
||||
</div>
|
||||
|
||||
{{- if gt (len $latest) 8 -}}
|
||||
{{- if gt (len $latest) 4 -}}
|
||||
<div class="relative z-10 mt-14 text-center">
|
||||
<a href="/posts/" class="btn btn-outline">View All {{ len $latest }} Posts {{ partial "icon.html" "arrow-right" }}</a>
|
||||
<a href="/posts/" class="btn btn-outline">View All {{ len $posts }} Posts {{ partial "icon.html" "arrow-right" }}</a>
|
||||
</div>
|
||||
{{- end -}}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user