API Reference 0.3.24dart_web_toolkit_roleCommandRole

CommandRole abstract class

CommandRole interface. The interface defines methods for setting, getting, removing states and properties. <p>Allows ARIA Accessibility attributes to be added to widgets so that they can be identified by assistive technology.</p>

ARIA roles define widgets and page structure that can be interpreted by a reader application/device. There is a set of abstract roles which are used as building blocks of the roles hierarchy structural and define the common properties and states for the concrete roles. Abstract roles cannot be set to HTML elements.

There are states and properties that are defined for a role. As roles are organized in a hierarchy, a role has inherited and own properties and states which can be set to the element.

For more details about ARIA roles check The Roles Model .

abstract class CommandRole extends WidgetRole {

}

Extends

RoletypeRole > WidgetRole > CommandRole

Subclasses

ButtonRole

Methods

abstract String get(Element element) #

inherited from RoletypeRole

Gets the role for the element {@code element}. If none is set, "" is returned.

@param element HTML element @return The role attribute value

abstract String getName() #

inherited from RoletypeRole

Gets the role name

@return The role name

abstract void remove(Element element) #

inherited from RoletypeRole

Removes the role for element {@code element}

@param element HTML element

abstract void set(Element element) #

inherited from RoletypeRole

Sets the role to element {@code element}

@param element HTML element