Edit this page

WAI-ARIA Support

This article demonstrates how to enable and use the WAI-ARIA support of the RadToggleButton control.

The WAI-ARIA Suite defines an approach to make web content and web applications more accessible to people with disabilities. RadToggleButton offers WAI-ARIA support.

In order to enable the WAI-ARIA support, set the RadToggleButton control's EnableAriaSupport property to true and, optionally, set the inner properties (DescribedBy and Label) of the AriaSettings composite tag to the desired values as shown in Example 1.

Example 1: Enabling WAI-ARIA support for RadToggleButton

<telerik:RadToggleButton ID="RadToggleButton1" runat="server" EnableAriaSupport="true">
    <AriaSettings DescribedBy="someElementId" Label="Some Label Value" />
    <ToggleStates>
        <telerik:ButtonToggleState Text="First state">
        </telerik:ButtonToggleState>
        <telerik:ButtonToggleState Text="Second state">
        </telerik:ButtonToggleState>
    </ToggleStates>
</telerik:RadToggleButton>
note

The implementation of the WAI ARIA support is achieved entirely client-side (using JavaScript) by appending different attributes and appropriate WAI-ARIA roles to the DOM elements. This is done because an HTML document containing ARIA attributes will not pass validation if they are added on the server.

See Also