mirror of
https://github.com/svemagie/blog-eleventy-indiekit.git
synced 2026-04-02 16:44:56 +02:00
feat: add posting frequency sparklines to all post type pages
Each collection page (articles, notes, photos, bookmarks, likes, replies, reposts) now shows its own sparkline next to the heading, showing that specific post type's frequency over the last 12 months.
This commit is contained in:
@@ -10,7 +10,13 @@ pagination:
|
||||
permalink: "replies/{% if pagination.pageNumber > 0 %}page/{{ pagination.pageNumber + 1 }}/{% endif %}"
|
||||
---
|
||||
<div class="h-feed">
|
||||
<h1 class="text-2xl sm:text-3xl font-bold text-surface-900 dark:text-surface-100 mb-2">Replies</h1>
|
||||
<div class="flex flex-wrap items-center gap-4 mb-2">
|
||||
<h1 class="text-2xl sm:text-3xl font-bold text-surface-900 dark:text-surface-100">Replies</h1>
|
||||
{% set sparklineSvg = collections.replies | postingFrequency %}
|
||||
{% if sparklineSvg %}
|
||||
<span class="opacity-60 dark:opacity-40 text-surface-500 dark:text-surface-400">{{ sparklineSvg | safe }}</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
<p class="text-surface-600 dark:text-surface-400 mb-6 sm:mb-8">
|
||||
My responses to posts across the web.
|
||||
<span class="text-sm">({{ collections.replies.length }} total)</span>
|
||||
|
||||
Reference in New Issue
Block a user