[whatwg] validationMessage

On Tue, Nov 10, 2009 at 12:23 PM, Michelangelo De Simone <micdesim at gmail.com
> wrote:

> What is the rationale about this choice? A simpler behavior with a
> predetermined list of return values (eg: i.validationMessage ==
> VALUEMISSING) could be much more efficient for authors and implementors to
> deal with, IMHO.
>

I tend to agree.

>From https://bugs.webkit.org/show_bug.cgi?id=27959#c29 , where this was
implemented for WebKit:
"This patch sure does seem to be an eloquent argument for not having all
these localized strings in the HTML5 form element design! I don't see a lot
of value of returning these strings that might not even be in the same
language as the
website. I wish we could get that changed." -- Darin Adler

My oversimplified view of this is:
* Providing a way for the webpage to specify validation constraints and
understand when they have not been met -- good
* Directing the UA to step into this process and show the user messages
about the validation failures, which don't take into account context the web
page has -- bad

This seems like an attempt to make life slightly easier on webpage authors
by providing boilerplate UI if they don't want to write anything.  But I see
that as a small benefit with significant edge cases.  Authors are already
expected to supply the textual content in the page, the text in alerts,
etc., so providing the text in the "validation failed" UI doesn't seem that
bad.  The UA can still do things like turn fields red or add warning sign
icons or something if it likes.

PK
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20091119/8274eff1/attachment.htm>

Received on Thursday, 19 November 2009 16:05:55 UTC