Skip to content
Back to skills

Common Accessibility

ASecurity

The form has three accessibility problems, but each has a direct fix: 1. Replace interactive `div` elements with native controls. Put them inside a real `<form>`, use `<input>` elements, and provide explicit programmatic labels: ```html <form aria-labelledby="login-heading"> <h1 id="login-heading">Sign in</h1> <label for="email">Email address</label> <input id="email" name="email" type="email" autocomplete="email" required aria-describedby="email-error"> <p id="email-error" role="alert" hidde...

  • 584 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 5, 2026
development

Security analysis

A100/100

Pro scans all 11 files and shows the line behind each finding

Scanned September 5, 2026

npx -y skills add HoangNguyen0403/agent-skills-standard --skill common-accessibility --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Common Accessibility?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Common Accessibility
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/hoangnguyen0403-common-accessibility-bd1bc72f/badge)](https://www.skillsdirectory.com/skills/hoangnguyen0403-common-accessibility-bd1bc72f)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
The form has three accessibility problems, but each has a direct fix:

1. Replace interactive `div` elements with native controls. Put them inside a real `<form>`, use `<input>` elements, and provide explicit programmatic labels:

```html
<form aria-labelledby="login-heading">
  <h1 id="login-heading">Sign in</h1>

  <label for="email">Email address</label>
  <input id="email" name="email" type="email"
         autocomplete="email" required
         aria-describedby="email-error">
  <p id="email-error" role="alert" hidden>Please enter a valid email address.</p>

  <label for="password">Password</label>
  <input id="password" name="password" type="password"
         autocomplete="current-password" required
         aria-describedby="password-error">
  <p id="password-error" role="alert" hidden>Enter your password.</p>

  <button type="submit">Sign in</button>
</form>
```

The actual error elements should be shown only when relevant; when shown, set the corresponding input’s `aria-invalid="true"`. Placeholder text can be an optional example or hint, but it is not a replacement for a persistent `<label>` because it disappears and has poor contrast.

2. Verify the blue submit button’s color combination rather than assuming blue is accessible. Normal button text needs at least a 4.5:1 contrast ratio against its background; the button’s boundary and other state indicators need sufficient non-text contrast. Do not use color alone to convey success or failure—include visible text or an icon with an accessible name.

3. Add a clearly visible keyboard focus style, preferably with `:focus-visible`, and do not remove the browser outline unless a replacement is provided:

```css
button:focus-visible,
input:focus-visible {
  outline: 2px solid #123a70;
  outline-offset: 2px;
}
```

The outline must have at least 3:1 contrast against adjacent colors and remain visible in every state. Keep the natural DOM/tab order, avoid positive `tabindex` values, and ensure all fields and the submit action work without a pointer.

Also check that the page has a logical heading structure and one main landmark, that validation changes are announced without excessive interruption, and that server-side errors are associated with the relevant control. Run axe-core with zero critical violations, then test the complete login flow by keyboard, with NVDA or VoiceOver, and at 200% zoom.

Files in this skill

  • eval-1.baseline.md3.9 KB
  • eval-1.with-skill.md2.6 KB
  • eval-2.baseline.md2.7 KB
  • eval-2.with-skill.md2.3 KB
  • eval-3.baseline.md2.2 KB
  • eval-3.with-skill.md2 KB
  • trigger-1.md145 B
  • trigger-2.md127 B
  • trigger-3.md128 B
  • trigger-4.md131 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in development →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.