Token导航 LogoToken导航

Agent Skill · 前端设计

flutter-accessibility-audit(Flutter 无障碍审核)

用于辅助无障碍访问检查、页面可用性审计和前端可访问性改进。它适合让 Agent 检查语义标签、键盘操作、颜色对比、ARIA 属性和自动化检测结果。使用时需要结合真实页面和浏览器验证,不应只依赖静态文本判断;涉及修复建议时,应兼顾设计系统、组件复用和 WCAG 等通用无障碍规范。

flutter-accessibility-audit 是前端设计类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为需要联网;许可证信息还不明确,第三方扫描已通过,按安装量在前端设计类的 10,216 个 Skill 里排第 312。

总安装 36,466周安装 1,528GitHub Stars 1,264下载 11,779核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:flutter-accessibility-audit(Flutter 无障碍审核)
来源仓库:https://github.com/flutter/skills
仓库路径:skills/flutter-accessibility-audit
安装命令:
npx skills add https://github.com/flutter/skills --skill flutter-accessibility-audit
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/flutter/skills --skill flutter-accessibility-audit

这个 Skill 是做什么的

前端设计类 Skill 关注页面结构、视觉规范和组件写法,输出通常是可运行的界面代码。

用于辅助无障碍访问检查、页面可用性审计和前端可访问性改进,适合审查语义标签与键盘操作。支持检查颜色对比、ARIA 属性和自动化检测结果,需结合真实页面验证。使用时不应仅依赖静态文本判断,应兼顾设计系统与 WCAG 规范。

安装方式:github,命令:npx skills add https://github.com/flutter/skills --skill flutter-accessibility-audit。建议确认项目测试框架与运行命令,避免为了通过检测而破坏逻辑。

来源仓库内路径:skills/flutter-accessibility-audit

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/flutter/skills --skill flutter-accessibility-a…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要需要联网,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

flutter-accessibility-audit 怎么安装?

在终端执行 npx skills add https://github.com/flutter/skills --skill flutter-accessibility-audit。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

flutter-accessibility-audit 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

flutter-accessibility-audit 需要什么权限?

权限级别是需要联网。该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

flutter-accessibility-audit 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

flutter-accessibility-audit 用的人多吗?

公开数据是累计安装 36,466 次,近一周安装 1,528 次,下载 11,779 次,GitHub 1,264 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

flutter-accessibility-audit 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。
  • 来源仓库有 1,264 星,维护活跃度相对可查。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理前端设计类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

前端设计类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
frontend-design

前端设计 · Codex、Claude

8,823,360126,072只读MIT通过
vercel-composition-patterns

Vercel 组合模式 · Codex、Claude

3,858,81625,893需要联网MIT通过
vercel-react-native-skills

Vercel React native skills 前端 · Codex、Claude

2,468,66425,878只读MIT通过
adapt

adapt 搜索 · Codex、Claude

2,027,04023,125操作浏览器未明确通过
bolder

bolder 分析 · Codex、Claude

2,004,28823,130只读未明确通过
flutter-accessibility-audit

Flutter 无障碍审核 · 本页

36,4661,264需要联网未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Implementing Flutter Accessibility

Contents

Managing Semantics

Rely on Flutter's standard widgets (e.g., TabBar, MenuAnchor) for automatic semantic role assignment whenever possible. When building custom components or overriding default behaviors, explicitly define the UI element's purpose using the Semantics widget.

  • Wrap custom UI components in a Semantics widget.
  • Assign the appropriate SemanticsRole enum value to the role property to define the element's purpose (e.g., button, list, heading).
  • If building for Flutter Web, note that Flutter translates these roles into corresponding ARIA roles in the HTML DOM.
  • Enable web accessibility explicitly. It is disabled by default for performance. Either instruct users to press the invisible aria-label="Enable accessibility" button, or force it programmatically in your main() function.

Auditing Accessibility

Implement the following workflows to verify that your application meets accessibility standards.

Task Progress: Platform-Specific Scanning

Copy this checklist to track your manual auditing progress across target platforms:

  • If testing on Android:

1. Install the Accessibility Scanner from Google Play. 2. Enable it via Settings > Accessibility > Accessibility Scanner > On. 3. Tap the Accessibility Scanner checkmark icon over your running app to initiate the scan.

  • If testing on iOS:

1. Open the ios folder in Xcode and run the app on a Simulator. 2. Navigate to Xcode > Open Developer Tools > Accessibility Inspector. 3. Select Inspection > Enable Point to Inspect and click UI elements to verify attributes. 4. Select Audit > Run Audit to generate an issue report.

  • If testing on Web:

1. Open Chrome DevTools. 2. Inspect the HTML tree under the semantics host node. 3. Navigate to the Elements tab and open the Accessibility sub-tab to inspect exported ARIA data. 4. Visualize semantic nodes by running the app with: flutter run -d chrome --profile --dart-define=FLUTTER_WEB_DEBUG_SHOW_SEMANTICS=true.

Task Progress: Automated Testing

Integrate Flutter's Accessibility Guideline API into your widget tests to catch contrast, target size, and labeling issues automatically.

  • Create a dedicated test file (e.g., test/a11y_test.dart).
  • Initialize the semantics handle using tester.ensureSemantics().
  • Assert against androidTapTargetGuideline (48x48px minimum).
  • Assert against iOSTapTargetGuideline (44x44px minimum).
  • Assert against labeledTapTargetGuideline.
  • Assert against textContrastGuideline (3:1 minimum for large text).
  • Dispose of the semantics handle at the end of the test.

Debugging the Semantics Tree

When semantic nodes are incorrectly placed or missing, execute the following feedback loop to identify and resolve the discrepancies.

  1. Run validator: Trigger a dump of the Semantics tree to the console.

- Enable accessibility via a system tool or SemanticsDebugger. - Invoke debugDumpSemanticsTree() (e.g., bind it to a GestureDetector's onTap callback for easy triggering during debugging).

  1. Review errors: Analyze the console output to locate missing labels, incorrect roles, or improperly nested semantic nodes.
  2. Fix: Wrap the offending widgets in Semantics or MergeSemantics widgets, apply the correct SemanticsRole, and repeat step 1 until the tree accurately reflects the visual UI.

Examples

Programmatically Enabling Web Accessibility

Force the Semantics tree to build immediately on Flutter Web.

import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
import 'package:flutter/semantics.dart';

void main() {
  runApp(const MyApp());
  if (kIsWeb) {
    SemanticsBinding.instance.ensureSemantics();
  }
}

Explicitly Defining Semantic Roles

Assign explicit list and list-item roles to a custom layout.

import 'package:flutter/material.dart';
import 'package:flutter/semantics.dart';

class MyCustomListWidget extends StatelessWidget {
  const MyCustomListWidget({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Semantics(
      role: SemanticsRole.list,
      explicitChildNodes: true,
      child: Column(
        children: <Widget>[
          Semantics(
            role: SemanticsRole.listItem,
            child: const Padding(
              padding: EdgeInsets.all(8.0),
              child: Text('Content of the first custom list item.'),
            ),
          ),
          Semantics(
            role: SemanticsRole.listItem,
            child: const Padding(
              padding: EdgeInsets.all(8.0),
              child: Text('Content of the second custom list item.'),
            ),
          ),
        ],
      ),
    );
  }
}

Automated Accessibility Testing

Implement the Accessibility Guideline API in a widget test.

import 'package:flutter_test/flutter_test.dart';
import 'package:your_accessible_app/main.dart';

void main() {
  testWidgets('Follows a11y guidelines', (tester) async {
    final SemanticsHandle handle = tester.ensureSemantics();
    await tester.pumpWidget(const AccessibleApp());

    // Check tap target sizes
    await expectLater(tester, meetsGuideline(androidTapTargetGuideline));
    await expectLater(tester, meetsGuideline(iOSTapTargetGuideline));

    // Check labels and contrast
    await expectLater(tester, meetsGuideline(labeledTapTargetGuideline));
    await expectLater(tester, meetsGuideline(textContrastGuideline));

    handle.dispose();
  });
}

平台分布

Codex

37.18%
按下载量换算4,379

Claude

29.87%
按下载量换算3,518

Cursor

16.07%
按下载量换算1,893

Gemini CLI

9.5%
按下载量换算1,119

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills