From b36247bbf21b814edbbb97060a44e8b3337e8ae6 Mon Sep 17 00:00:00 2001 From: Gilbert Sanchez Date: Sun, 28 Jun 2026 08:40:55 -0700 Subject: [PATCH 1/8] fix(a11y,seo): add accessible names and fill missing meta descriptions Resolves the most widespread Unlighthouse findings across the site: - link-name / button-name (scored 0 on all crawled pages): icon-only social links, mobile-menu toggle, dropdown chevron, and back-to-top button now have aria-labels; decorative icons marked aria-hidden. - meta-description (scored 0 on 65 list/taxonomy/author/pagination pages): these had neither .Description nor .Summary, leaving the tag empty. Add a summary-then-title fallback so every page emits a non-empty description. - unsized-images / image-aspect-ratio: footer CC BY-SA and Netlify badges get explicit width/height matching intrinsic ratio. Co-Authored-By: Claude Opus 4.8 --- .../layouts/_default/baseof.html | 11 ++++++++- .../layouts/partials/footer.html | 24 +++++++++---------- .../layouts/partials/header.html | 15 +++++++----- 3 files changed, 31 insertions(+), 19 deletions(-) diff --git a/themes/powershell-community/layouts/_default/baseof.html b/themes/powershell-community/layouts/_default/baseof.html index fd442cf2a..3f8a7513b 100644 --- a/themes/powershell-community/layouts/_default/baseof.html +++ b/themes/powershell-community/layouts/_default/baseof.html @@ -9,7 +9,16 @@ {{- $ogTitle := cond .IsHome .Site.Title .Title -}} {{- $title := cond .IsHome .Site.Title (printf "%s — %s" .Title $brand) -}} {{- $metaDesc := .Site.Params.description -}} - {{- if .Description }}{{ $metaDesc = .Description }}{{ else if not .IsHome }}{{ $metaDesc = (.Summary | plainify | truncate 160) }}{{ end -}} + {{- if .Description -}} + {{- $metaDesc = .Description -}} + {{- else if not .IsHome -}} + {{- $summary := .Summary | plainify | strings.TrimSpace -}} + {{- if $summary -}} + {{- $metaDesc = ($summary | truncate 160) -}} + {{- else if .Title -}} + {{- $metaDesc = printf "%s on PowerShell.org — articles, podcasts, and resources from the PowerShell community." .Title -}} + {{- end -}} + {{- end -}} {{- $socialDesc := $metaDesc -}} {{- with .Params.og_description }}{{ $socialDesc = . }}{{ end -}} {{- $ogImage := partial "og-image.html" . -}} diff --git a/themes/powershell-community/layouts/partials/footer.html b/themes/powershell-community/layouts/partials/footer.html index 69336d3d2..74dc84daa 100644 --- a/themes/powershell-community/layouts/partials/footer.html +++ b/themes/powershell-community/layouts/partials/footer.html @@ -13,21 +13,21 @@

PowerShell.org

The community hub for PowerShell enthusiasts, automaters, and professionals worldwide.

@@ -85,19 +85,19 @@

{{ .Site.Params.summit.title }}

Terms of Use Contact - Licensed under CC BY-SA 4.0 + Licensed under CC BY-SA 4.0 - Deploys by Netlify + Deploys by Netlify - \ No newline at end of file diff --git a/themes/powershell-community/layouts/partials/header.html b/themes/powershell-community/layouts/partials/header.html index 17d41ac46..3ffa49af4 100644 --- a/themes/powershell-community/layouts/partials/header.html +++ b/themes/powershell-community/layouts/partials/header.html @@ -59,17 +59,18 @@

PowerShell.org

Summit {{ .Site.Params.summit.year }} - +
-
@@ -93,8 +94,10 @@

PowerShell.org

class="block text-gray-700 hover:text-blue-600 hover:bg-gray-50 px-3 py-2 rounded-md text-base font-medium flex-1 {{ if hasPrefix $.RelPermalink .URL }}text-blue-600 bg-blue-50{{ end }}"> {{ .Name }} -