HenrikJoreteg / Happy.js

$('form').isHappy() – Lightweight, extensible form validation plugin for jQuery/Zepto.js
http://projects.joreteg.com/Happy.js/
MIT License
412 stars 123 forks source link

Accessibilty Imporovements #26

Closed MarnuLombard closed 10 years ago

MarnuLombard commented 10 years ago

Changed to after(errorEl) for the sake of screenreaders

→ Screenreaders don't automatically "see" DOM elements inserted before inputs → Inserting errors after the relevant input allows blind people to easily recieve these errors if the site uses happy.js → Where I learned this was: alistapart.com/article/designing-for-easy-interaction

Added role=alert for accessibility too

MarnuLombard commented 10 years ago

Awesome. Glad I could contribute. :smile: