Design Token System Enforces Accessibility Constraints at Build Time
The accessibility-token-manifest defines the complete set of accessibility constraints applied to the design token system: minimum contrast ratios, minimum touch target sizes, permitted font weight ranges, spacing rules, and interaction pattern requirements. The token-accessibility-enforcer validates all token combinations against this manifest at build time. The ci-accessibility-lint-runner integrates this into the Dart/Flutter CI pipeline via the flutter-accessibility-lint-config, running on every pull request. The accessibility-audit-runner performs runtime checks on rendered widget trees. Together, these three layers create defense-in-depth that prevents accessibility regressions from reaching production. The design-token-provider acts as the single source of truth that all UI components consume, ensuring enforcement is universal.
User Story
Acceptance Criteria
- Given a developer creates a pull request that introduces a new color token combination, when the ci-accessibility-lint-runner executes, then token combinations violating contrast requirements cause the CI check to fail and the PR cannot be merged
- Given a developer adds a new interactive widget without applying accessible-touch-target-wrapper, when flutter-accessibility-lint-config runs, then a lint warning flags the missing touch target enforcement
- Given the accessibility-token-manifest is updated to reflect a new WCAG requirement, when the token-accessibility-enforcer runs against existing tokens, then any tokens no longer compliant with the updated manifest are flagged for remediation
- Given a QA engineer runs the accessibility-audit-runner against a built app binary, when all screens are evaluated, then a machine-readable report is generated listing all violations by screen, component, and violation type
- Given the app has been in active development for 6 months with 10+ new screens added, when a WCAG 2.2 AA audit is performed by an external accessibility specialist, then zero contrast failures and zero touch target failures are found across all screens
Business Value
Without automated enforcement, accessibility standards degrade over time as new developers join and deadlines create pressure to skip manual checks. The workshop documentation identifies universal accessibility as a MUST HAVE for all four organizations. Investing in build-time enforcement converts a continuous manual QA cost into a one-time tooling investment that protects the app indefinitely. This is particularly critical because the app will serve multiple organizations, each adding requirements over time — ensuring the design token system acts as a compliance firewall is the only scalable approach.
Components
- Accessibility Token Manifest data
- Token Accessibility Enforcer service
- CI Accessibility Lint Runner infrastructure
- Flutter Accessibility Lint Configuration infrastructure
- Design Token Provider data
- Accessibility Design Token Enforcer infrastructure
- Accessibility Audit Runner infrastructure
- Contrast Ratio Validator Service service