Accessibility Testing

Installation
SKILL.md

Accessibility Testing

This skill enables the agent to perform thorough accessibility audits of web pages and components against the Web Content Accessibility Guidelines (WCAG) 2.1 at AA and AAA conformance levels. The agent identifies violations across four principles — Perceivable, Operable, Understandable, Robust — and generates structured compliance reports with specific code fixes. It covers automated checks (color contrast, missing alt text, ARIA misuse), semi-automated checks (keyboard navigation flows, focus management), and manual check guidance (screen reader announcements, cognitive load).

Workflow

  1. Define Audit Scope and Conformance Target: Determine which pages, components, or user flows to audit, and whether the target is WCAG 2.1 AA (most common legal requirement) or AAA (highest conformance). Identify the assistive technologies to consider: screen readers (NVDA on Windows, VoiceOver on macOS/iOS, TalkBack on Android), keyboard-only navigation, and magnification tools.

  2. Run Automated Scans: Execute automated accessibility analysis using axe-core or Lighthouse. These tools detect approximately 30-40% of WCAG violations automatically, including missing alt attributes, insufficient color contrast ratios, missing form labels, duplicate IDs, invalid ARIA roles, and missing document language. Capture each violation with its WCAG criterion reference (e.g., 1.4.3 Contrast Minimum), severity (critical, serious, moderate, minor), the affected HTML element, and the CSS selector path.

  3. Perform Keyboard Navigation Testing: Manually trace every interactive flow using only Tab, Shift+Tab, Enter, Space, Escape, and arrow keys. Verify that focus order matches visual order, that focus indicators are visible (minimum 2px outline with 3:1 contrast), that modal dialogs trap focus correctly, and that no keyboard traps exist. Document any flow where a keyboard user cannot complete a task that a mouse user can.

  4. Test with Screen Readers: Navigate the page with at least one screen reader to verify that all content is announced correctly. Confirm that images have meaningful alt text (or alt="" for decorative images), that headings form a logical hierarchy (no skipped levels), that landmarks (<nav>, <main>, <aside>) are present, and that dynamic content updates are announced via aria-live regions.

  5. Generate the Compliance Report: Produce a structured report organized by WCAG principle and criterion. For each violation, include: the criterion number and name, the severity level, the affected element's HTML snippet, an explanation of why it fails, and the specific code fix. Include a summary table with pass/fail counts per principle and an overall conformance statement.

  6. Provide Remediation Code: For every violation, supply a concrete before-and-after code snippet showing the exact fix. Group fixes by component or page region so developers can address them systematically rather than one element at a time.

Usage

Related skills
Installs
GitHub Stars
78
First Seen