skip-navigation
它能做什么
这个技能检查页面顶部是否有可用键盘操作的跳过导航链接。它面向希望重复菜单易于跳过的网站构建者。
适用场景
- ✓你请智能体为网站添加跳过导航链接的时候。
- ✓页面有很长的菜单,键盘用户每次访问都必须经过它的时候。
- ✓你在页面加载后立即按 Tab 键测试,并希望第一个停留点是跳过链接的时候。
技能链接
https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/skip-navigation/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请帮我在网站中添加“跳到主要内容”链接,让我可以用键盘跳过菜单吗?”
每周 5 个新技能,1 分钟读完。
工作原理
智能体会在页面顶部添加一个视觉上隐藏、获得焦点时才出现的链接。它使用 id 指向主要内容,并检查页面加载后立即按 Tab 键时,第一个停留的是否为该链接。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Include a skip navigation link
Skip links save keyboard and screen reader users from tabbing through 50+ navigation items on every page visit—turning a frustrating experience into an efficient one.
Quick Reference
- Add a 'Skip to main content' link as the first focusable element
- Hide visually but show on focus with CSS
- Link to main content using id='main-content'
- Test by pressing Tab immediately after page load
Check
Verify that a 'Skip to main content' link is present and functional at the beginning of the page.
Fix
Add a visually hidden skip link that becomes visible on focus and links to the main content area.
Explain
Explain how skip links improve efficiency for keyboard users by allowing them to bypass repeated navigation elements.
Code Review
Review the rendered markup and interactive states that affect Include a skip navigation link. Flag exact elements, roles, labels, focus behavior, or keyboard interactions that violate the rule, and note how to verify the fix with browser accessibility tooling or assistive tech.
For full implementation details, code examples, and framework-specific guidance,
see references/rule.md.
Rule page: https://frontendchecklist.io/rules/accessibility/skip-navigation
常见问题
这为什么有用?
这个技能说,它可以让键盘用户和屏幕阅读器用户免于每个页面都要按 Tab 键经过大量导航项。
链接是如何隐藏的?
这个技能说,用 CSS 将其在视觉上隐藏,只在获得焦点时显示。
如何测试?
这个技能建议页面加载后立即按 Tab 键,并检查跳过链接是否为第一个停留点。
详情
作者的原始描述
Use when reviewing rendered HTML, interactive components, or design-system patterns related to Include a skip navigation link. Check native semantics first, then inspect keyboard behavior, focus flow, accessible names, and screen-reader output where relevant.
热度
- GitHub 星标
- 75k
- 排名
- #3026
- 许可证
- MIT
- 更新时间
- 2026/10/31
评论
- …
同一仓库的更多技能
frontendchecklist
75k使用命令行工具,依据 380 多条关于无障碍、速度、SEO 和安全的规则,检查前端代码和线上页面。
frontend-checklist-global
75k依据全部 386 条 Front-End Checklist 规则审查前端项目,并为发现的每个问题给出具体修复方法。
404-page
75k检查你的页面缺失提示是否提供有用的链接,并返回真正的 404 状态,帮助迷路的访客找到方向。
about-page
75k审查你的网站是否有清晰的关于页面,说明由谁运营,以建立访客和搜索引擎的信任。