From a2875e8c106f7b8e8c7fd57ec59b43cd295d20f7 Mon Sep 17 00:00:00 2001
From: Marc LeBlanc <7050295+marcleblanc2@users.noreply.github.com>
Date: Thu, 17 Sep 2026 02:50:39 -0600
Subject: [PATCH] a11y: Add main and region landmarks
axe-core flags every page with landmark-one-main and region
violations (moderate): there is no , so page content sits
outside any landmark and screen reader users cannot jump to it.
Make the page content container a on the home, docs and 404
pages, and make the home page hero a labelled by its
heading. Both keep their classes, so the layout does not change.
Amp-Thread-ID: https://ampcode.com/threads/T-01a0ae7e-ae2c-7423-be36-eb9c5884b1e0
Co-authored-by: Amp
---
src/app/[...slug]/page.tsx | 4 ++--
src/app/not-found.tsx | 4 ++--
src/app/page.tsx | 4 ++--
src/components/Hero.tsx | 8 ++++++--
4 files changed, 12 insertions(+), 8 deletions(-)
diff --git a/src/app/[...slug]/page.tsx b/src/app/[...slug]/page.tsx
index 9b5f38d8a..01681c596 100644
--- a/src/app/[...slug]/page.tsx
+++ b/src/app/[...slug]/page.tsx
@@ -58,7 +58,7 @@ const PostLayout = async ({params}: Props) => {
const content = (
<>
-
+
@@ -66,7 +66,7 @@ const PostLayout = async ({params}: Props) => {
-
+
!post.preview).map(post => post.url);
export default function NotFound() {
return (
-
+
404
@@ -19,6 +19,6 @@ export default function NotFound() {
-
+
);
}
diff --git a/src/app/page.tsx b/src/app/page.tsx
index ab6f7e380..01a78b0fe 100644
--- a/src/app/page.tsx
+++ b/src/app/page.tsx
@@ -24,13 +24,13 @@ const PostLayout = () => {
return (
<>
-
+
>
);
};
diff --git a/src/components/Hero.tsx b/src/components/Hero.tsx
index 8da0f8072..863981f70 100644
--- a/src/components/Hero.tsx
+++ b/src/components/Hero.tsx
@@ -15,12 +15,16 @@ function TrafficLightsIcon(props: React.ComponentPropsWithoutRef<'svg'>) {
export function Hero() {
return (
-