microsoft/vscode-documentdb/accessibility-aria-expert
Claude Code and agent skill by microsoft/vscode-documentdb
- community
- verified
Checking that the SKILL.md file is still in the repository.
Detects and fixes accessibility issues in React/Fluent UI webviews. Use when reviewing code for screen reader compatibility, fixing ARIA labels, ensuring keyboard navigation, adding live regions for status messages, or managing focus in dialogs.
Install
npx vskill@latest install microsoft/vscode-documentdb/accessibility-aria-expertSKILL.md
Accessibility Expert for Webviews
Verify and fix accessibility in React/Fluent UI webview components.
When to Use
- Review webview code for accessibility issues
- Fix double announcements from screen readers
- Add missing
aria-labelto icon-only buttons or form inputs - Make tooltips accessible to keyboard/screen reader users
- Announce status changes (loading, search results, errors)
- Manage focus when dialogs/modals open
- Group related controls with proper labels
Core Pattern: Tooltip Accessibility
For a badge whose tooltip must be reachable by keyboard, use the package component and keep the tooltip as a description:
- The visible content is the name through
aria-labelledby. - Tooltip content is the supplementary description through
aria-describedby. - The badge carries
role="group", because ARIA cannot name a role-less element. - Browser-computed results do not prove what a real screen reader says.
Detection Rules
1. Tooltip Content Never Reaches the Accessibility Tree
❌ Problem: the tooltip declares no ARIA relationship, so its content is invisible to assistive technology — and the aria-label here only restates the visible text
✅ Fix: declare the relationship and let the tooltip be the description
relationship="description" wires aria-describedby to the tooltip. Do not also copy the tooltip text into aria-label: that announces it twice (rule 2). Use relationship="label" only when the trigger has no visible text of its own.
2. Composed Badge Name Repeats Its Description
❌ Problem: Tooltip details occur in both the name and description
✅ Fix: Let visible content name FocusableBadge; keep details in the description
3. Redundant aria-label (NOT Needed)
❌ Problem: aria-label identical to visible text adds no value
✅ Fix: Remove redundant aria-label OR make it more descriptive
Keep aria-label only when it adds information:
4. Icon-Only Button Missing aria-label
❌ Problem: No accessible name
✅ Fix: Add aria-label
5. Decorative Elements Not Hidden
❌ Problem: Progress bar announced unnecessarily
✅ Fix: Hide decorative elements
6. Input Missing Accessible Name
❌ Problem: SpinButton/Input without accessible name
✅ Fix: Add aria-label or associate with label element
7. Visible Label Not in Accessible Name
❌ Problem: aria-label doesn't contain visible text (breaks voice control)
✅ Fix: Accessible name must contain visible label exactly
Voice control users say "click Refresh" – only works if accessible name contains "Refresh".
8. Status Changes Not Announced
❌ Problem: Screen reader doesn't announce dynamic content
✅ Fix: Use the Announcer component
Use for: loading states, search results, success/error messages.
9. Dialog Opens Without Focus Move
❌ Problem: Focus stays on trigger when modal opens
✅ Fix: Move focus programmatically
10. Related Controls Without Group Label
❌ Problem: Buttons share visual label but screen reader misses context
✅ Fix: Use role="group" with aria-labelledby
When to Use aria-hidden
DO use on:
- Decorative icons, spinners, progress bars
- Visual separators (\
|\, \—\)
Last resort only: visible text that a composed aria-label already covers. Prefer naming the element _from_ its visible content with aria-labelledby, which needs no hiding at all — that is what FocusableBadge and MetricCard do.
DO NOT use on:
- The only accessible content (hides it completely)
- Interactive/focusable elements
- Error messages or alerts
FocusableBadge Pattern
For keyboard-accessible badges with tooltips:
- Import
FocusableBadgefrom@microsoft/vscode-ext-webview-fluentui/components. - Keep
Tooltipat the call site withrelationship="description". - Use
focusable={false}only for plain badges in a mixed list; never infer focusability from an
accessible-name override.
For rich tooltip content that visually repeats the badge name, set the content slot's aria-label to only the supplementary details. For truncated values, keep the visible label and truncated value as the badge name and the full value as the description; do not use relationship="label".
When you name a focusable container yourself rather than using these components, give it a role. ARIA forbids naming the generic role, so aria-labelledby on a bare div (or on Fluent's Badge or Card, neither of which sets a role) is a name a conforming screen reader may discard. role="group" is usually the least-weight role that makes the name legitimate.
Screen Reader Announcements
Use the Announcer component for WCAG 4.1.3 (Status Messages) compliance.
Basic Usage
Props
when: Announces when this transitions fromfalsetotruemessage: The message to announce (usel10n.t()for localization)politeness:'assertive'(default, interrupts) or'polite'(waits for idle)
Key Points
- Placement doesn't matter - screen readers monitor all live regions regardless of DOM position; place near related UI for code readability
- Store relevant state (e.g.,
documentCount) to derive dynamic messages - Use `l10n.t()` for messages - announcements must be localized
- Condition resets automatically - when
whengoes back tofalse, it's ready for the next announcement - Prefer 'assertive' for user-initiated actions, 'polite' for background updates
Quick Checklist
- [ ] Icon-only buttons have
aria-label - [ ] Form inputs have associated labels or
aria-label - [ ] Tooltips declare a
relationship; their text is not also copied intoaria-label - [ ] Visible text is not hidden with
aria-hiddento make room for a composedaria-label - [ ] Redundant aria-labels removed (identical to visible text)
- [ ] Visible button labels are contained in the accessible name (for voice control)
- [ ] Decorative elements have
aria-hidden={true} - [ ] Badges with keyboard-reachable tooltips use
FocusableBadge+relationship="description" - [ ] Focusable elements carrying
aria-labelledbyhave a role (ARIA cannot namegeneric) - [ ] Status updates use
Announcercomponent - [ ] Focus moves to dialog/modal content when opened
- [ ] Related controls wrapped in
role="group"witharia-labelledby
References
- WCAG 2.1.1 Keyboard
- WCAG 2.4.3 Focus Order
- WCAG 2.5.3 Label in Name
- WCAG 4.1.2 Name, Role, Value
- WCAG 4.1.3 Status Messages
- See
packages/vscode-ext-webview-fluentui/src/components/FocusableBadge/README.mdfor the badge pattern
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files. Certified 10 Mar 2026.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryChecking.github/skills/accessibility-aria-expert/SKILL.md
Popularity
- Repository stars
- 21
- Repository forks
- 8
- 7-day trend score
- 15
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 16 Mar 2026, 8 months ago.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/microsoft/vscode-documentdb/accessibility-aria-expert)