Happy.js icon indicating copy to clipboard operation
Happy.js copied to clipboard

Custom positioning for error messages

Open zizther opened this issue 13 years ago • 2 comments

Add the ability to place the error message before or after the input. Sometimes it is nice that it floats next to the input, so maybe the error message can be placed inside a certain element.

zizther avatar Jul 24 '12 16:07 zizther

There was a PR that changed the default behavior to after, and it was an accessibility fix which ranks pretty high IMO.

I don't really want to add a funky config option to change that to before or after, but maybe being able to pass in a selector would allow everyone the flexibility they need if .after() doesn't work for them.

wraithgar avatar Mar 02 '14 04:03 wraithgar

The errorTarget option is also available on the field level. I just use that to direct my error messages on a per-field basis.

beerendlauwers avatar Aug 31 '15 10:08 beerendlauwers