Skip to content

feat(a11y,kits): add TL601-TL606 3D/XR accessibility linter and fix kit contrast - #100

Merged
jbingham merged 1 commit into
mainfrom
feat/a11y-linter-and-kit-contrast
Nov 14, 2026
Merged

jbingham merged 1 commit into
mainfrom
feat/a11y-linter-and-kit-contrast

Conversation

@jbingham

Copy link
Copy Markdown
Collaborator

Summary

  • 3D / XR Accessibility Linter (TL601–TL606): Adds 6 built-in accessibility diagnostics to three-live-cli validate / compile and the MCP server (three_live_validate / three_live_compile) aligned with WCAG 2.1/2.2 and W3C XAUR:
    • TL601 (warning — WCAG 2.1 SC 1.4.11): Foreground mesh luminance contrast < 3.0:1 against the dark studio viewport (#0f172a).
    • TL602 (warning — WCAG 2.1 SC 1.4.3): 3D text / callout label contrast < 4.5:1.
    • TL603 (warning — WCAG 2.2 SC 2.5.8 / W3C XAUR): Interactive target covers < 0.4% of viewport (< 2.5° XR visual angle).
    • TL604 (info — W3C XAUR): Interactive node missing a descriptive mesh.name or userData.xr.label.
    • TL605 (info — WCAG 2.1 SC 2.3.3): Continuous orbit.speed > 2.5 rad/s or follow.stiffness > 25.0 vestibular comfort check.
    • TL606 (info — WCAG 2.1 SC 1.4.1): Interactive sibling meshes of identical size relying solely on red-green hue separation.
  • 3D Building Blocks Contrast Audit & Thumbnail Regeneration: Updates dark metallic/slate material colors across examples/kits/catalog-data.js, adds automated rendered-pixel WCAG 2.1 Level AA (>= 3.0:1) contrast verification to scripts/generate_kits_gallery.js, and regenerates all 153 .webp thumbnails (examples/kits/thumbs/*.webp) with 0 contrast failures (minimum rendered contrast 3.17:1).

Test Plan

  • cargo test --lib (100 passed; 0 failed)
  • cargo test --test three_compiler_test -- --test-threads=4 (87 passed; 0 failed, including test_a11y_linter_tl601_to_tl606)
  • node scripts/generate_kits_gallery.js (153/153 variants verified with rendered contrast >= 3.17:1)

…it contrast

Dark metallic and slate materials in 3D building blocks (such as `0x111827` and `0x1e293b` IC packages, enclosures, and structural beams) rendered with less than `3.0:1` luminance contrast against the dark studio viewport (`#0f172a`), failing WCAG 2.1 Level AA non-text contrast (SC 1.4.11), and scenes lacked automated static accessibility checks during validation and compilation.

Add 6 built-in 3D/XR accessibility diagnostics (`TL601`–`TL606`) to the spatial linter (`three-live-cli validate` / `compile` and MCP `three_live_validate` / `three_live_compile`) aligned with WCAG 2.1/2.2 and W3C XAUR, and update dark material colors across the 153-variant 3D building blocks catalog (`examples/kits/catalog-data.js`) and thumbnails (`examples/kits/thumbs/*.webp`) with automated rendered-pixel contrast verification in `scripts/generate_kits_gallery.js` so all 153 variants achieve at least `3.17:1` contrast.

TAG=agy
CONV=96f4bdc7-359e-449d-87b1-f461ac1f234d
MARKDOWN=true
@jbingham
jbingham merged commit 4284d1b into main Nov 14, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants