[whatwg] Default values for step

Will Levine wlevine at gmail.com
Fri Jun 25 08:28:36 PDT 2004

I started reading through the spec and have a couple comments so far.

<input name="foo" type="number">
This little snip of code is used for, very not surprisingly, inputting
a number. This make sense. However, what I find misleading is that
this code cannot be used for inputing any number, but can only be used
for inputing integers (because the default step is 1). This, at least
to me, does not make sense. The type is called number, not integer,
not certainnumbers. (obviously, we can't call the type integer,
because it doesn't have to be an integer if the step is changed). I
would guess that more forms on the web would require integers than
not, but many will need fractional values and it doesn't seem to make
sense to constrain the type (by default) based on this.

Also, I have some questions about the default step on the datetime and
time types. Admittedly, I can't think of any real cases where one
would need to specify time precise to the second or fraction of a
second in a Web app as one could with step=any (but I'm assuming there
must be one since that kind of precision is included in the text). In
this way, the default step makes sense. However, I still can only
think of a few cases where it would be necessary to specify time
precise to the minute. Does one ever schedule a meeting at 5:54,
rather than at 6:00? It seems to me that in most cases, the increment
would be 5, 15, 30, or 60 minutes, and not 1 minute. Because there are
a number of increments that would be commonly used, it would make
sense to me to just have the default step as any and authors could set
it as needed.

I'd like to here what you all have to say.

-Qill Levine

More information about the whatwg mailing list