accesslint-diff
它能做什么
比较同一网页两个版本的无障碍问题。它会显示新出现的问题、已修复的问题,以及仍然存在的问题数量。
适用场景
- ✓比较页面的两个版本,查看无障碍方面的变化。
- ✓检查更新后是否引入了新的无障碍问题。
- ✓确认修复后无障碍问题是否已解决。
技能链接
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/accesslint-diff/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“比较我网站首页的当前版本和开发版本,列出新增的无障碍问题。”
每周 5 个新技能,1 分钟读完。
工作原理
它会分析两个版本的页面(一个基准版本和一个新版本),并对比无障碍测试的结果。输出内容只关注差异:新增问题、已修复问题,以及仍然存在的问题总数。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
When to Use
- Compare a requested page's accessibility findings between verified base and candidate revisions.
- Report introduced, fixed and still-present findings without changing application source.
1. Establish isolated snapshots
This package does not bundle the CLI or browser. Verify the current installed tool schema or a reviewed pinned package version first. Do not evaluate $ARGUMENTS or branch/URL text as shell syntax.
- Resolve the requested base and head to full commit SHAs; identify whether staged, unstaged or untracked content belongs to the candidate.
- Preserve the user's checkout. Prefer isolated worktrees or recoverable snapshots for base and candidate; do not switch their branch or pop an unrelated stash. A branch mode comparing only committed HEAD must disclose excluded local changes.
- Use each revision's reviewed lockfile and authorized build procedure. Serve base and candidate on separate local ports, wait for a deterministic ready selector and verify which revision each page actually serves. A fixed sleep is not a readiness check.
- Audit matching URLs, account state, viewport, selectors, engine version and rule configuration. Keep private snapshots in a fresh owner-only directory, not a predictable shared
/tmpfilename. Capture the baseline and candidate using the actual supported CLI flags; do not invent commands when integration is unavailable. - Compare findings and inspect selector drift or removed content. Record inaccessible states and manual WCAG checks separately. Never promise full restoration without verifying file status and content.
2. Report
Accessibility diff — http://localhost:3000/ vs main (94 rules, live DOM)
2 new · 1 fixed · 4 pre-existing hidden
New — Critical
- color-contrast — 2.1:1 (needs 4.5:1), #bbb on #fff
where: main > p.subtitle fix: darken to #767676
Fixed
- img-alt — <img src="old.jpg"> (no longer present)
Each new violation: where (selector verbatim + file:line (symbol) if source present — never fabricate), evidence, fix (mechanical change or NEEDS HUMAN).
Don't edit. For an explicitly authorized fix request, use the available accesslint-audit procedure and verify with the same controlled baseline. This report-only skill does not authorize a separate agent handoff.
3. Tear down
Close only browser processes, servers and snapshots created for this run. Preserve pre-existing sessions and recoverable work. Remove an isolated worktree only after needed evidence has been saved; never use a global browser stop command for cleanup.
Gotchas
- Diff output is limited to exercised pages/states and the selected automated rules; it is not a WCAG certification.
- Removed elements can disappear from an audit without being an accessible replacement. Inspect the user journey.
- Heavy DOM changes can invalidate selector matching; verify corresponding elements or run full audits of both snapshots.
- Report illustrative sample counts as examples, not measurements.
Limitations
- Use this skill only when the task clearly matches the scope described above.
- Do not treat the output as a substitute for environment-specific validation, testing, or expert review.
- Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.
常见问题
这是完整的无障碍审计吗?
不是。它只关注两个版本之间的差异。如需完整审计,请使用 “scan” 命令。
它会自动修复问题吗?
不会。这个命令只报告差异,不会修改代码或修复问题。
“已存在数量”是什么意思?
指的是基准版本中已经存在、并且在新版本中仍然存在的无障碍问题数量。
详情
作者的原始描述
Diff a live page's accessibility violations against a baseline — by default compares uncommitted changes (stash-based), or pass --branch [<name>] to diff against a branch. Reports only new violations introduced, violations fixed, and pre-existing count. Use `scan` for a full audit with no diffing.
热度
- GitHub 星标
- 48k
- 排名
- #3635
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
00-andruia-consultant
48k帮你的智能体启动或改进 AI 项目。它可以分析代码、推荐工具,并用西班牙语制定行动计划。
007
48k让你的智能体执行安全审计和威胁建模。它有助于保护项目免受攻击和漏洞的威胁。
10-andruia-skill-smith
48k帮你的智能体创建或改进 AI 工具。它可以定义工具的工作方式、编写文档,并验证其结构。
20-andruia-niche-intelligence
48k让你的智能体创建某个特定行业的摘要。它有助于借助可靠的信息来源,了解项目的背景、规则、使用模式和风险。