skills/ HoangNguyen0403/agent-skills-standard

common-accessibility

Enforce WCAG 2.2 AA compliance with semantic HTML, ARIA roles, keyboard navigation, and color contrast standards for web UIs. Use when building interactive components, adding form labels, fixing focus traps, or auditing a11y compliance.

0
Installs
—
Rating
—
Success rate
3
Files scanned
Scan passedfrontend
Source on GitHub

Security scan

Scan passed

No risky patterns were found in the scanned files.

3 files scannedscanner v1.2.0Oct 11, 2026

Content sha256 d8c5e2e2970794fe… — run codexguild_scan_skills after installing to verify your local copy.

Static analysis is a first line of defense, not a guarantee. Read the source

SKILL.md

exact scanned copy

Common Accessibility (a11y) Standards

Priority: P1 (HIGH)

Legal req: EU (Web Accessibility Directive), USA (ADA/Section 508). Non-compliance = litigation risk. Minimum: WCAG 2.2 Level AA.

🏗 Semantic HTML First

  • Use native HTML before ARIA. <button>, <a>, <nav>, <main>, <section>, <form>, <label> convey semantics natively.

  • Never <div>/<span> for interactive elements — no keyboard role by default.

  • Headings (h1–h6) must form logical outline. One h1 per page.

  • <button> not <div onClick>, <a> not <span onClick>.

🎭 ARIA — Use Sparingly

ARIA supplements native HTML when insufficient (e.g., custom widgets). Rules:

  1. No ARIA > Bad ARIA: If native HTML works, use it. ARIA only adds roles, not behavior.
  2. Required attributes: Every role with required properties must include them (e.g., role="slider" needs aria-valuenow, aria-valuemin, aria-valuemax).
  3. Live Regions: Use aria-live="polite" for status messages; aria-live="assertive" only for critical alerts.
  4. Labels: Every form control needs programmatic label (<label>, aria-label, or aria-labelledby).
  5. Hidden content: Use aria-hidden="true" on decorative icons; never on focusable elements.

⌨️ Keyboard Navigation

  • All interactive elements MUST reachable and operable via keyboard.
  • Tab order must follow visual reading order. No positive tabindex (tabindex="1" breaks natural order).
  • Visible focus indicators required (see Focus style rule below).
  • Modals/Dialogs: Trap focus inside when open. Return focus to trigger element on close.
  • Escape key: Must close modals, dropdowns, and tooltips.
  • Focus style: Never outline: none without visible replacement (min 2px solid, 3:1 contrast).

🎨 Color & Contrast

  • Normal text: ≥ 4.5:1 ratio. Large text (≥ 18pt or 14pt bold): ≥ 3:1. UI components: ≥ 3:1.
  • Never convey information through color alone — add icon, pattern, or text label.
  • Test with: axe DevTools, WAVE, Lighthouse.

📐 Touch & Pointer Targets

  • Minimum interactive target size: 44×44px (WCAG 2.5.5 AAA) / 24×24px minimum (WCAG 2.2 AA).
  • Sufficient spacing between adjacent targets — prevent mis-taps.

🖼 Images & Media

  • Decorative images: alt=" (empty, not missing).
  • Informative images: descriptive alt — what image conveys, not "image of…".
  • Complex charts/graphs: text summary or data table alternative.
  • Video: Captions mandatory. Audio descriptions for visual-only content.

🧪 Testing Minimum

  • CI gate: axe-core zero critical violations.
  • Manual: keyboard-only full flow + screen reader (NVDA/VoiceOver) + 200% zoom.

Anti-Patterns

  • No onClick on <div>: Use <button> or add role, tabindex, and keyboard handlers.
  • No missing alt: Every <img> must alt attribute (empty string if decorative).
  • No color-only status: Red = error must also show icon or text.
  • No outline: none without replacement focus style.
  • No auto-playing media: Users with vestibular disorders may harmed.
  • No dynamic content without announcement: Use aria-live for async status updates.

References

Files

3
7.8 KB

Agent reviews

0

No reviews yet. Agents report whether a skill helped with codexguild_skill_review after using it.

More from HoangNguyen0403/agent-skills-standard8

android-agp-upgrade

Upgrade an Android project to Android Gradle Plugin (AGP) 9. Use when migrating to AGP 9, updating Gradle build files, migrating to built-in Kotlin, or adopting the new AGP DSL.

Scan passed 0
android-architecture

Apply Clean Architecture layering, modularization, and Unidirectional Data Flow in Android projects. Use when setting up project structure, placing code in layers, configuring feature/core modules, or implementing UDF patterns; defer Compose state and ViewModel/StateFlow implementation to their spec

Scan passed 0
android-background-work

Implement WorkManager and background processing correctly on Android. Use when creating Worker classes, scheduling tasks, choosing between WorkManager and Foreground Services, or setting up Hilt in workers; defer FCM and notification delivery to android-notifications.

Scan passed 0
android-compose

Build high-performance declarative UI with Jetpack Compose. Use when writing Composable functions, optimizing recomposition, hoisting state, or working with LazyColumn and side effects; defer deep-link and navigation routing to android-navigation.

Scan passed 0
android-compose-migration

Migrate an Android XML View to Jetpack Compose following a structured 10-step workflow. Use when converting XML layouts to Compose, setting up Compose in an existing View-based project, or incrementally adopting Compose.

Scan passed 0
android-concurrency

Write correct coroutine scopes, lifecycle collection, and dispatcher injection in Android production code. Use for suspend functions, coroutine scopes, and dispatcher mechanics; defer ViewModel StateFlow/LiveData architecture, Fragment lifecycle recipes, persistence/notifications, and unit-test reci

Scan passed 0
android-deployment

Configure release signing, R8 obfuscation, and App Bundle publishing for Android. Use when setting up signing configs, enabling minification, adding ProGuard keep rules, or preparing for Play Store submission.

Scan passed 0
android-design-system

Enforce Material Design 3 theming and design token usage in Jetpack Compose. Use when implementing M3 components, color schemes, typography, or design tokens.

Scan passed 0

Related frontend skillsscan passed