<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.28.2">
</HEAD>
<BODY>
On Mon, 2010-11-01 at 06:15 +0200, timeless wrote:
<BLOCKQUOTE TYPE=CITE>
<PRE>
On Mon, Nov 1, 2010 at 4:31 AM, TAMURA, Kent <<A HREF="mailto:tkent@chromium.org">tkent@chromium.org</A>> wrote:
> A team in Google tried to use <input type=number> for a product, and they
> decided
> not to use it.
> What they needed was a control to select an integer from a specific integer
> range
> such as 1 - 16. The number type control in Opera and WebKit allow a user to
> input
> out-of-range value even if the control has min=1 and max=16 attributes.
> It's not
> a good UI and the reason why they doesn't use type=number.
> They need a number control which
> - doesn't allow any keyboard / cut&paste operations and
> So, a text field part is read-only, but the spin-buttons work.
Not allowing cut isn't really reasonable. If you want to prevent cut
from working completely, that's fine.
i.e. when i cut "15" (because i use cut instead of copy consistently),
then your web application is free to reset the value to the default,
but "15" should go into my clipboard.
When I select paste to restore my "15", it needs to work. You don't
have the right to mess with that.
> - always has a valid value.
set one in onchange
</PRE>
</BLOCKQUOTE>
That's a javascript event, and shouldn't be relied upon for this sort of thing really.
<BLOCKQUOTE TYPE=CITE>
<PRE>
> "required" by default, and sanitization algorithm may be different.
> I'm not sure how to solve this issue. Introducing new content attribute or
> another number type?
No.
</PRE>
</BLOCKQUOTE>
<BR>
<BR>
<TABLE CELLSPACING="0" CELLPADDING="0" WIDTH="100%">
<TR>
<TD>
Thanks,<BR>
Ash<BR>
<A HREF="http://www.ashleysheridan.co.uk">http://www.ashleysheridan.co.uk</A><BR>
<BR>
<BR>
</TD>
</TR>
</TABLE>
</BODY>
</HTML>