aria-valuenow
Characteristics
Type:
- String
Related Concepts:
- XForms
- range
- start
See Related:
- aria-valuetext
Used in Roles:
- range
Inherits into Roles:
- progressbar
- scrollbar
- slider
- spinbutton
Value:
- number
Sets or retrieves the current value of the element.
This property applies to elements with an aria role of progressbar, slider, or spinbutton.
The aria-valuemin and aria-valuemax properties together specify the allowable range of values, whereas the aria-valuenow property specifies the value currently selected.
If the current value is not known (for example, an indeterminate progress bar), the author should not set the aria-valuenow attribute. If the aria-valuenow attribute is absent, no information is implied about the current value. If the aria-valuenow has a known maximum and minimum, the author should provide properties for aria-valuemax and aria-valuemin.
The value of aria-valuenow is a decimal number. If the range is a set of numeric values, then aria-valuenow is one of those values. For example, if the range is [0, 1], a validaria-valuenow is 0.5. A value outside the range, such as -2.5 or 1.1, is invalid.
For progressbar elements and scrollbar elements, assistive technologies should render the value to users as a percent, calculated as a position on the range from aria-valuemin to aria-valuemax if both are defined, otherwise the actual value with a percent indicator. For elements with role slider and spinbutton, assistive technologies should render the actual value to users.
When the rendered value cannot be accurately represented as a number, authors should use the aria-valuetext attribute in conjunction with aria-valuenow to provide a user-friendly representation of the range's current value. For example, a slider may have rendered values of small, medium, and large. In this case, the values of aria-valuenow could range from 1 through 3, which indicate the position of each value in the value space, but the aria-valuetext would be one of the strings: small, medium, or large.
Note: If aria-valuetext is specified, assistive technologies render that instead of the value of aria-valuenow.
Note For cross-browser compatibility, always use the aria attribute syntax to access and modify aria properties, for example object.setAttribute("aria-valuenow", newValue).
Syntax
HTML <element aria-valuenow="p" ... > JavaScript object.setAttribute("aria-valuenow",value);var value = object.getAttribute("aria-valuenow");
Microsoft Active Accessibility Properties:
- get_accValue
UI Automation Properties:
- ValueProperty (RangeValue Pattern)
UI Automation AriaProperties Property:
- valuenow