From 7fef95672232d7246f7f973ce3b8b9256f29e36c Mon Sep 17 00:00:00 2001 From: Maris Popens Date: Sat, 17 Oct 2026 22:54:58 +0300 Subject: [PATCH] fix(site): cap page titles at 60 chars before the site suffix --- site/layouts/baseof.html | 2 +- site/layouts/partials/head-seo.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/site/layouts/baseof.html b/site/layouts/baseof.html index 82d4765..92bb690 100644 --- a/site/layouts/baseof.html +++ b/site/layouts/baseof.html @@ -8,7 +8,7 @@ -{{ if .IsHome }}Eraser — data broker removal{{ else }}{{ .Title }} · Eraser{{ end }} +{{ if .IsHome }}Eraser — data broker removal{{ else }}{{ strings.Truncate 60 .Title }} · Eraser{{ end }} {{ with .Params.robots }}{{ end }} diff --git a/site/layouts/partials/head-seo.html b/site/layouts/partials/head-seo.html index a699449..9c55e0f 100644 --- a/site/layouts/partials/head-seo.html +++ b/site/layouts/partials/head-seo.html @@ -1,7 +1,7 @@ {{- /* Open Graph, Twitter card and JSON-LD. Kept in one partial so baseof.html stays readable and the publisher Organization is defined once. */ -}} {{- $isHome := .IsHome -}} -{{- $title := cond $isHome "Eraser — data broker removal" (printf "%s · Eraser" .Title) -}} +{{- $title := cond $isHome "Eraser — data broker removal" (printf "%s · Eraser" (strings.Truncate 60 .Title)) -}} {{- $desc := or .Description .Site.Params.description -}} {{- $org := dict "@type" "Organization" "name" "Drum and Bytes" "url" "https://drumandbytes.com" -}}