whatgoodisaroad/validity

CSS classes to invalid inputs

Closed this issue · 2 comments

Is there any way to add classes to the invalid inputs through configuration?

The summary output mode will apply this class by default

.validity-erroneous { border:solid 2px #f56600 !important; }
http://validity.thatscaptaintoyou.com/Demos/index.htm#SummaryCSS

That's right, thanks markvantilburg.

If you want to apply your own class, or do anything to the input, you could write your own output mode and apply the class in your version of the raise method.