flutter_accessibility_scanner
1.2.0, released 7 weeks ago by an unverified publisher
Scan Flutter widget trees for WCAG 2.1 accessibility issues with fix hints.
WASM-ready
What it does
Walks the live render tree to report accessibility issues against WCAG 2.1, including missing labels, low contrast, small tap targets, and focus problems. It provides fix hints, in-app dev overlays, widget test integrations, and JSON/Markdown CI reports.
AI-written summary of version 1.2.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to audit your Flutter app for WCAG 2.1 accessibility compliance.
- You want to catch accessibility issues automatically in widget tests and CI pipelines.
Skip it when
- Your app does not use standard Flutter widgets or render trees.
Strengths
- Covers multiple detection types such as contrast, tap targets, focus, and labels.
- Integrates seamlessly into widget tests and CI workflows with JSON and Markdown reports.
- Provides an in-app overlay for quick interactive debugging.
Weaknesses
- Automated scans cannot catch all accessibility problems, manual testing with screen readers is still necessary.
- Text over complex images or gradients falls back to assumptions and cannot always be accurately measured.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 0
Add to dev_dependencies and use the AccessibilityScanner in widget tests or wrap your MaterialApp with AccessibilityScannerWidget.
testWidgets('checkout screen is accessible', (tester) async {
await tester.pumpWidget(const MaterialApp(home: CheckoutScreen()));
await tester.pumpAndSettle();
final report = await AccessibilityScanner().scan(
tester.element(find.byType(CheckoutScreen)),
);
expect(report.issues, isEmpty);
});