feat: AI/KI disclosure footer — shared/ai-disclosure.js + all 54 sites

Self-injecting script following impressum.js pattern:
- data-tone attribute: playful | serious | minimal | none
- Reads document.documentElement.lang for KI (de) vs AI (en)
- MutationObserver on lang attr for i18n toggle compat
- All tones link to msbls.de/ki
- Injected into all 54 custom sites with data-tone="playful"
- Template infra: base.html includes script, render.sh reads disclosure.tone
- disclosure.tone added to 3 example site.yaml files

Implements m/onepager#2
This commit is contained in:
m
2026-04-01 13:26:04 +02:00
parent 5c92a7b021
commit 84b28d64f5
60 changed files with 138 additions and 0 deletions

View File

@@ -32,6 +32,7 @@ font_secondary=$(yq -r '.vars.font_secondary // "Inter"' "$SITE_YAML")
emoji=$(yq -r '.vars.emoji // ""' "$SITE_YAML")
cta_text=$(yq -r '.vars.cta.text // ""' "$SITE_YAML")
cta_href=$(yq -r '.vars.cta.href // "#"' "$SITE_YAML")
disclosure_tone=$(yq -r '.disclosure.tone // "minimal"' "$SITE_YAML")
year=$(date +%Y)
# i18n: helper to generate data-de/data-en attribute string
@@ -234,6 +235,7 @@ BEGIN {
-e "s|{{cta_href}}|${cta_href}|g" \
-e "s|{{year}}|${year}|g" \
-e "s|{{domain}}|${domain}|g" \
-e "s|{{disclosure_tone}}|${disclosure_tone}|g" \
-e "s|{{title_i18n}}|$(echo "$title_i18n" | sed 's/[&/\]/\\&/g')|g" \
-e "s|{{description_i18n}}|$(echo "$description_i18n" | sed 's/[&/\]/\\&/g')|g" \
-e "s|{{role_i18n}}|$(echo "$role_i18n" | sed 's/[&/\]/\\&/g')|g" \