Loading...
Loading...
Compare original and translation side by side
| Dimension | Impact |
|---|---|
| Legal | Legislation in most jurisdictions (ADA, EAA, Section 508, EN 301 549) requires digital products to be accessible. Non-compliance carries litigation risk and financial penalties. |
| Ethical | Roughly 16% of the global population lives with some form of disability. Excluding them from digital services is a choice, not an inevitability. |
| Business | Accessible products reach a wider audience, improve SEO (structured content helps crawlers), reduce support costs, and correlate with higher overall usability scores. |
| Technical quality | Accessibility constraints force clean markup, proper semantics, and separation of concerns -- all of which improve maintainability. |
| 维度 | 影响 |
|---|---|
| 法律层面 | 大多数司法管辖区的立法(ADA、EAA、第508条款、EN 301 549)都要求数字产品具备可访问性,不合规会带来诉讼风险和经济处罚。 |
| 伦理层面 | 全球约有16%的人口存在某种形式的残疾,将他们排除在数字服务之外是人为选择,而非不可避免的结果。 |
| 商业层面 | 无障碍产品能够覆盖更广泛的受众,提升SEO效果(结构化内容对爬虫更友好),降低支持成本,同时往往对应更高的整体可用性评分。 |
| 技术质量层面 | 无障碍约束会倒逼开发者编写干净的标记代码、使用合理的语义、实现关注点分离,这些都能提升代码的可维护性。 |
| Principle | Question It Answers | Examples |
|---|---|---|
| Perceivable | Can users sense the content? | Text alternatives for images, captions for video, sufficient color contrast, resizable text |
| Operable | Can users interact with every control? | Keyboard operability, enough time to complete tasks, no seizure-triggering animations, clear navigation |
| Understandable | Can users comprehend the content and UI behavior? | Readable language, predictable navigation, input assistance and error messages |
| Robust | Does it work across assistive technologies? | Valid markup, proper use of ARIA, compatibility with screen readers and other tools |
| 原则 | 回答的问题 | 示例 |
|---|---|---|
| 可感知(Perceivable) | 用户能否感知到内容? | 图片的文本替代说明、视频字幕、足够的色彩对比度、可调整大小的文本 |
| 可操作(Operable) | 用户能否与所有控件交互? | 键盘可操作、充足的任务完成时间、无诱发癫痫的动画、清晰的导航 |
| 可理解(Understandable) | 用户能否理解内容和UI的行为逻辑? | 易懂的语言、可预测的导航、输入辅助和错误提示 |
| 健壮性(Robust) | 能否在各类辅助技术上正常运行? | 合法的标记代码、正确使用ARIA、兼容屏幕阅读器和其他工具 |
| Level | Target Audience | Typical Requirement |
|---|---|---|
| A | Bare minimum -- removes the most severe barriers | Most legal and procurement requirements start here |
| AA | Industry standard -- addresses the majority of barriers for most users | Required by ADA, EAA, Section 508, and most organizational policies |
| AAA | Highest standard -- not always achievable for all content types | Aspirational goal; apply selectively where feasible |
| 等级 | 适用受众 | 典型要求 |
|---|---|---|
| A | 最低要求——消除最严重的访问障碍 | 大多数法律和采购要求的最低门槛 |
| AA | 行业标准——解决大多数用户面临的绝大多数障碍 | ADA、EAA、第508条款和大多数组织政策的强制要求 |
| AAA | 最高标准——并非所有内容类型都能实现 | 愿景目标,在可行的场景下选择性应用 |
| Instead Of | Use | Why |
|---|---|---|
| | Buttons are focusable, announce their role, and respond to Enter and Space |
| | Links announce as "link," support middle-click, and appear in link lists |
| | Landmark elements let screen reader users jump between page regions |
| | Lists announce item count and position ("item 3 of 7") |
| | Table headers associate data cells with their labels for screen readers |
Styled | | Native form controls have label association, validation, and assistive tech support built in |
| 不推荐写法 | 推荐写法 | 原因 |
|---|---|---|
| | 按钮默认可聚焦、会播报自身角色、支持Enter和Space键触发 |
| | 链接会被播报为「链接」、支持中键打开、会出现在链接列表中 |
| | 地标元素让屏幕阅读器用户可以在页面区域之间快速跳转 |
| 搭配 | 列表会播报条目总数和位置(「共7条,第3条」) |
| 搭配 | 表头会将数据单元格和对应标签关联,方便屏幕阅读器识别 |
用样式化 | | 原生表单控件自带标签关联、校验和辅助技术支持 |
<h1><h2><h4><h1><h2><h4>| Issue | Impact | Fix |
|---|---|---|
| Missing alt text on images | Screen readers announce the filename or nothing | Add descriptive |
| Insufficient color contrast | Users with low vision cannot read text | Meet 4.5:1 ratio for normal text, 3:1 for large text (AA) |
| No keyboard access to interactive elements | Keyboard and switch users are completely blocked | Use native interactive elements or add |
| Missing form labels | Screen readers cannot announce what an input is for | Associate every input with a |
| Auto-playing media | Disorienting for screen reader users, harmful for those with cognitive disabilities | Never auto-play; if unavoidable, provide a visible pause/stop control |
| Missing skip link | Keyboard users must tab through the entire nav on every page | Add a skip-to-main-content link as the first focusable element |
| No focus indicator | Keyboard users lose track of their position on the page | Never remove |
| Missing page language | Screen readers may mispronounce content | Set |
| Inaccessible dynamic content | Screen readers do not announce changes that happen after page load | Use ARIA live regions to announce dynamic updates |
| Missing document title | Screen reader users cannot identify the page when switching tabs | Set a unique, descriptive |
| Touch targets too small | Motor-impaired users cannot reliably tap small controls | Minimum 24x24 CSS pixels (AA), prefer 44x44 for comfortable interaction |
| Motion and animation | Can cause vestigo, nausea, or seizures | Respect |
| 问题 | 影响 | 修复方案 |
|---|---|---|
| 图片缺失alt文本 | 屏幕阅读器会播报文件名或者不播报任何内容 | 添加描述性的 |
| 色彩对比度不足 | 低视力用户无法看清文本 | 普通文本对比度达到4.5:1,大文本达到3:1(AA级要求) |
| 交互元素不支持键盘访问 | 键盘和切换设备用户完全无法使用 | 使用原生交互元素,或者添加 |
| 表单缺失标签 | 屏幕阅读器无法播报输入框的用途 | 通过 |
| 媒体自动播放 | 会让屏幕阅读器用户感到混乱,对认知障碍用户有害 | 永远不要自动播放;如果不可避免,要提供可见的暂停/停止控件 |
| 缺失跳转链接 | 键盘用户每次进入页面都需要tab遍历整个导航栏 | 添加跳转到主内容的链接作为页面第一个可聚焦元素 |
| 无焦点指示器 | 键盘用户无法追踪自己在页面中的位置 | 永远不要直接移除 |
| 缺失页面语言设置 | 屏幕阅读器可能会错误发音内容 | 在 |
| 动态内容无无障碍适配 | 屏幕阅读器不会播报页面加载后发生的内容变化 | 使用ARIA live区域播报动态更新 |
| 缺失文档标题 | 屏幕阅读器用户切换标签时无法识别页面 | 为每个页面设置唯一、描述性的 |
| 触摸目标太小 | 运动障碍用户无法可靠点击小控件 | 最小24x24 CSS像素(AA级要求),优先使用44x44保证交互舒适度 |
| 动效和动画 | 可能导致眩晕、恶心或癫痫 | 尊重 |
<!-- Explicit association -->
<label for="email">Email address</label>
<input type="email" id="email" name="email" required>
<!-- Implicit association (wrapping) -->
<label>
Email address
<input type="email" name="email" required>
</label><!-- 显式关联 -->
<label for="email">Email address</label>
<input type="email" id="email" name="email" required>
<!-- 隐式关联(嵌套) -->
<label>
Email address
<input type="email" name="email" required>
</label>aria-describedbyaria-invalid="true"aria-describedbyaria-invalid="true"requiredaria-required="true"requiredaria-required="true"| Element | Minimum Ratio |
|---|---|
| Normal text (under 18pt / 14pt bold) | 4.5:1 |
| Large text (18pt+ / 14pt+ bold) | 3:1 |
| UI components and graphical objects | 3:1 |
prefers-color-scheme| 元素 | 最低对比度 |
|---|---|
| 普通文本(小于18pt / 14pt加粗) | 4.5:1 |
| 大文本(18pt及以上 / 14pt加粗及以上) | 3:1 |
| UI组件和图形对象 | 3:1 |
prefers-color-scheme| Reference | Contents |
|---|---|
| ARIA Patterns | When to use ARIA, roles and properties, widget patterns (tabs, modals, accordions, dropdowns), live regions, landmark roles |
| Keyboard and Focus | Tab order, arrow key navigation, focus trapping, skip links, focus restoration, visible focus indicators, touch targets |
| Testing Strategies | Automated tools, manual testing checklist, screen reader testing, contrast verification, accessibility tree, CI integration |
| 参考 | 内容 |
|---|---|
| ARIA模式 | ARIA的使用场景、角色和属性、组件模式(标签页、模态框、手风琴、下拉菜单)、live区域、地标角色 |
| 键盘与焦点 | Tab顺序、方向键导航、焦点 trapping、跳转链接、焦点恢复、可见焦点指示器、触摸目标 |
| 测试策略 | 自动化工具、手动测试 Checklist、屏幕阅读器测试、对比度校验、无障碍树、CI集成 |
| Situation | Recommended Skill |
|---|---|
| Building REST or GraphQL APIs with accessible error responses | Install |
| Security headers that affect accessibility (CSP, iframe restrictions) | Install |
| Testing accessible components with unit and integration tests | Install |
| Performance optimization that does not sacrifice accessibility | Install |
krzysztofsurdy/code-virtuosoknowledge-virtuosokrzysztofsurdy/code-virtuosoknowledge-virtuosokrzysztofsurdy/code-virtuosoknowledge-virtuosokrzysztofsurdy/code-virtuosoknowledge-virtuoso