-
@AT_Fresh_Dev @racheleditullio I have one that does both browser-based validation and supports custom error strings (without messing with accessibility). Give me a few minutes to dig it up and dust it off…
-
@AT_Fresh_Dev @racheleditullio I’ve clearly worked on too many projects at this point. I’ll post bits as I find them.
-
@AT_Fresh_Dev @racheleditullio Here’s a wicked old jQuery-based validator that does HTML5 validation and has a fallback with support for custom strings at the form level. github.com/easy-designs/easy-validation/blob/master/src/jquery.easy-validation.js The logic pattern is solid for understanding how to push custom errors. I have one for individual fields too…
-
@AT_Fresh_Dev @racheleditullio Another interesting find in the archives: Custom DOM-based rules for complex field patterns that are controlled at the markup level github.com/easy-designs/jquery.easyValidationRules.js
-
@AT_Fresh_Dev @racheleditullio Another for managing
required
on checkboxes (where HTML5 validation fails) github.com/easy-designs/jquery.easy-checkbox-required.js -
@AT_Fresh_Dev @racheleditullio A bunch of validation-related code samples are here (starting on slide 95): presentations.aaron-gustafson.com/EhL5Kj/the-features-of-highly-effective-forms
-
@AT_Fresh_Dev @racheleditullio Slide 111 in that deck has a solid example of the markup pattern I use for inline errors. It’s worth noting that
aria-errormessage
can also be used, but support is currently spotty, so I’ll stick witharia-describedby
for now a11ysupport.io/tests/tech__aria__aria-errormessage-with-aria-invalid-true -
@AT_Fresh_Dev @racheleditullio 👆🏻 that was the one I was looking for. Should be easy to follow, but let me know if you have questions.