diff --git a/.claude/skills/accessibility/SKILL.md b/.claude/skills/accessibility/SKILL.md index 6b30fa13a..6b4a9500c 100644 --- a/.claude/skills/accessibility/SKILL.md +++ b/.claude/skills/accessibility/SKILL.md @@ -12,12 +12,10 @@ This project builds on **shadcn/ui** primitives which provide strong built-in a1 All interactive elements without visible text must have an `aria-label`: ```typescript -// Icon buttons -// Folder toggles
``` @@ -45,11 +43,15 @@ Use the shadcn/ui `Label` component for proper form associations. - **Escape**: Close dialogs, cancel editing, deselect - **Tab**: Move focus between interactive elements +The `Input` component has built-in `onEnter` and `onEscape` props: + ```typescript -// The Input component has built-in onEnter and onEscape props +``` + +Everything else handles the keys itself: -// For non-Input elements, handle manually +```typescript onKeyDown={(e) => { if (e.key === "Enter" && !e.shiftKey) { e.preventDefault(); @@ -78,13 +80,11 @@ The dialog component already handles this — use `preventKeyboardPropagation` p Use `sr-only` class for visually hidden but screen-reader-accessible text: ```typescript -// Close buttons with only an icon Close -// Command palette title {title} {description} @@ -95,19 +95,10 @@ Use `sr-only` class for visually hidden but screen-reader-accessible text: Use proper semantic elements and ARIA roles: -```typescript -// Navigation -