Skip to content

docs: repository-wide Mermaid diagram colour palette sweep (WCAG AA follow-up) #976

@ashleyshaw

Description

@ashleyshaw

Summary

Follow-up to PR #975, which introduced the WCAG 2.2 AA colour contrast validator and updated diagram standards (instructions/mermaid.instructions.md v2.0).

The validator found 36 contrast errors across the repository on first run — all caused by style X fill:#colour declarations without an explicit color property. In GitHub dark mode, Mermaid inherits white text, producing contrast ratios as low as ~1.1:1 against light pastel fills (WCAG AA minimum is 4.5:1).

Work Required

Sweep all 47 .md files that contain Mermaid diagrams and replace every old-style fill-only style declaration with an approved fill + color + stroke triple from the palette in instructions/mermaid.instructions.md:

Role fill color stroke
Information #dbeafe #1e3a5f #1e3a5f
Success #dcfce7 #14532d #14532d
Warning #fef3c7 #4a2c00 #b45309
Error / Alert #fee2e2 #7f1d1d #b91c1c
Documentation #f3e8ff #3b0764 #7e22ce
Neutral #f1f5f9 #0f172a #334155
Highlight #ecfdf5 #064e3b #059669

Acceptance Criteria

  • npm run validate:mermaid-contrast exits with code 0 (zero errors, zero warnings)
  • All 47 diagram files updated to use approved palette triples
  • npm run validate:mermaid-syntax and npm run validate:mermaid-accessibility continue to pass
  • PR targets develop

Files to Update

Run npm run validate:mermaid-contrast to get the current list of affected files and their specific style declarations to fix.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions