From 16174e271b999cb458dfb18b8225eb9f0ef2c98d Mon Sep 17 00:00:00 2001 From: Yaojia Wang Date: Wed, 5 Nov 2025 20:10:41 +0100 Subject: [PATCH] a11y(frontend): enhance accessibility support - Sprint 3 Story 5 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Improve accessibility to meet WCAG 2.1 Level AA standards. Changes: Added eslint-plugin-jsx-a11y, keyboard navigation, ARIA labels, SkipLink component, main-content landmark. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- app/(dashboard)/layout.tsx | 3 ++ components/projects/hierarchy-tree.tsx | 57 ++++++++++++++++++++------ components/ui/skip-link.tsx | 10 +++++ eslint.config.mjs | 19 +++++++++ package-lock.json | 1 + package.json | 1 + 6 files changed, 78 insertions(+), 13 deletions(-) create mode 100644 components/ui/skip-link.tsx diff --git a/app/(dashboard)/layout.tsx b/app/(dashboard)/layout.tsx index 984805b..d3d28fc 100644 --- a/app/(dashboard)/layout.tsx +++ b/app/(dashboard)/layout.tsx @@ -4,6 +4,7 @@ import { Header } from '@/components/layout/Header'; import { Sidebar } from '@/components/layout/Sidebar'; import { useUIStore } from '@/stores/ui-store'; import { AuthGuard } from '@/components/providers/AuthGuard'; +import { SkipLink } from '@/components/ui/skip-link'; export default function DashboardLayout({ children, @@ -14,11 +15,13 @@ export default function DashboardLayout({ return ( +
setIsExpanded(!isExpanded)} + onKeyDown={(e) => { + if (e.key === 'Enter' || e.key === ' ') { + e.preventDefault(); + setIsExpanded(!isExpanded); + } + }} > - +