From d8e982e3c3dee30114a0cf374763c2a3610b43f5 Mon Sep 17 00:00:00 2001 From: Ricardo Date: Thu, 5 Mar 2026 15:21:57 +0100 Subject: [PATCH] feat: always show AI Usage disclosure on posts Default aiTextLevel to "0" (None) when absent from frontmatter, so every post shows the collapsed AI disclosure line. Confab-Link: http://localhost:8080/sessions/648a550c-4f65-46be-b9a9-6b7e0fd90751 --- _includes/layouts/post.njk | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/_includes/layouts/post.njk b/_includes/layouts/post.njk index b8450ad..babf064 100644 --- a/_includes/layouts/post.njk +++ b/_includes/layouts/post.njk @@ -68,26 +68,24 @@ withBlogSidebar: true {# Rich reply context with h-cite microformat #} {% include "components/reply-context.njk" %} - {# AI usage disclosure — collapsed by default, placed after reply context #} - {% set aiTextLevel = aiTextLevel or ai_text_level %} + {# AI usage disclosure — always shown, collapsed by default, placed after reply context #} + {% set aiTextLevel = aiTextLevel or ai_text_level or "0" %} {% set aiCodeLevel = aiCodeLevel or ai_code_level %} {% set aiTools = aiTools or ai_tools %} {% set aiDescription = aiDescription or ai_description %} - {% if aiTextLevel or aiCodeLevel or aiTools %}
AI: - {% if aiTextLevel %}Text {% if aiTextLevel === "0" %}None{% elif aiTextLevel === "1" %}Editorial{% elif aiTextLevel === "2" %}Co-drafted{% elif aiTextLevel === "3" %}AI-generated{% endif %}{% endif %}{% if aiCodeLevel %}{% if aiTextLevel %} · {% endif %}Code {% if aiCodeLevel === "0" %}Human{% elif aiCodeLevel === "1" %}AI-assisted{% elif aiCodeLevel === "2" %}AI-generated{% endif %}{% endif %}{% if aiTools %}{% if aiTextLevel or aiCodeLevel %} · {% endif %}{{ aiTools }}{% endif %} + Text {% if aiTextLevel === "0" %}None{% elif aiTextLevel === "1" %}Editorial{% elif aiTextLevel === "2" %}Co-drafted{% elif aiTextLevel === "3" %}AI-generated{% endif %}{% if aiCodeLevel %} · Code {% if aiCodeLevel === "0" %}Human{% elif aiCodeLevel === "1" %}AI-assisted{% elif aiCodeLevel === "2" %}AI-generated{% endif %}{% endif %}{% if aiTools %} · {{ aiTools }}{% endif %} {% if aiDescription %}

{{ aiDescription }}

{% endif %}
- {% endif %} {# Pending syndication targets (for services like IndieNews that require u-syndication before webmention) #} {% if mpSyndicateTo %}