[RFC] Making default spinbutton values more consistent with the defaults for HTML5's input type="number"

Hi all.

We have an open issue [1] regarding the fact that the ARIA spinbutton
default value-related values are not consistent with HTML5's input
element with type="number".

At the moment, the ARIA spec states:
* If aria-valuemin is missing or not a number, it defaults to 0 (zero).
* If aria-valuemax is missing or not a number, it defaults to 100.
* If aria-valuenow is missing or not a number, it defaults to the value
  half way between aria-valuemin and aria-valuemax.
* If aria-valuenow is present but less than aria-valuemin, it defaults
  to the value of aria-valuemin.
* If aria-valuenow is present but greater than aria-valuemax, it
  defaults to the value of aria-valuemax.

HTML5's input element with type="number" [2] states that:
* The value attribute, if specified and not empty, must have a value
  that is a valid floating-point number.
* The value sanitization algorithm is as follows: If the value of the
  element is not a valid floating-point number, then set it to the
  empty string instead.
* The min attribute, if specified, must have a value that is a valid
  floating-point number.
* The max attribute, if specified, must have a value that is a valid
  floating-point number.

One possibility which was suggested is that ARIA use "-1" as the value
of the attributes which are missing or not a number. My questions are:

1. Will that pose any problems for any ATs or platform APIs?
2. For aria-valuenow, would it make more sense to set the value to the
   empty string if it is missing or not a number?
3. What do people think about nixing what we have (just for spinbutton
   values) and replacing it with text boiling down to user agents doing
   whatever they'd do given an HTML5 input type="number" with missing
   or non-numeric values?

I myself am leaning towards doing item 3 above and not doing the "-1" thing.

Thoughts?
--joanie

[1] https://www.w3.org/WAI/ARIA/track/issues/1002
[2]
https://www.w3.org/html/wg/drafts/html/master/semantics.html#number-state-(type=number)

Received on Thursday, 14 January 2016 19:17:25 UTC