Accessibility Addon
The Accessibility Addon helps detect accessibility issues using
the accessibility_tools
package.
Due to maintenance issues, the AccessibilityAddon
will no longer be shipped
with future Widgetbook versions. The addon is deprecated and you can use
the setup guide below to use it again in your app.
Setup
-
Add
accessibility_tools
to yourpubspec.yaml
file:pubspec.yamldependencies: accessibility_tools:
-
Create a new file called
accessibility_addon.dart
in yourwidgetbook_workspace
project, with the following content:addons/accessibility_addon.dartimport 'package:accessibility_tools/accessibility_tools.dart'; import 'package:widgetbook/widgetbook.dart'; class AccessibilityAddon extends BuilderAddon { AccessibilityAddon() : super( name: 'Accessibility', builder: (context, child) => AccessibilityTools( child: child, ), ); }
-
Start using the addon as follows:
Widgetbook.material( addons: [ AccessibilityAddon(), // ... ], );