-
ng
- function
- angular.bind
- angular.bootstrap
- angular.copy
- angular.element
- angular.equals
- angular.extend
- angular.forEach
- angular.fromJson
- angular.identity
- angular.injector
- angular.isArray
- angular.isDate
- angular.isDefined
- angular.isElement
- angular.isFunction
- angular.isNumber
- angular.isObject
- angular.isString
- angular.isUndefined
- angular.lowercase
- angular.module
- angular.noop
- angular.reloadWithDebugInfo
- angular.toJson
- angular.uppercase
- directive
- a
- form
- input
- input[checkbox]
- input[date]
- input[datetime-local]
- input[email]
- input[month]
- input[number]
- input[radio]
- input[text]
- input[time]
- input[url]
- input[week]
- ngApp
- ngBind
- ngBindHtml
- ngBindTemplate
- ngBlur
- ngChange
- ngChecked
- ngClass
- ngClassEven
- ngClassOdd
- ngClick
- ngCloak
- ngController
- ngCopy
- ngCsp
- ngCut
- ngDblclick
- ngDisabled
- ngFocus
- ngForm
- ngHide
- ngHref
- ngIf
- ngInclude
- ngInit
- ngKeydown
- ngKeypress
- ngKeyup
- ngList
- ngModel
- ngModelOptions
- ngMousedown
- ngMouseenter
- ngMouseleave
- ngMousemove
- ngMouseover
- ngMouseup
- ngNonBindable
- ngOpen
- ngPaste
- ngPluralize
- ngReadonly
- ngRepeat
- ngSelected
- ngShow
- ngSrc
- ngSrcset
- ngStyle
- ngSubmit
- ngSwitch
- ngTransclude
- ngValue
- script
- select
- textarea
- object
- angular.version
- type
- $cacheFactory.Cache
- $compile.directive.Attributes
- $rootScope.Scope
- angular.Module
- form.FormController
- ngModel.NgModelController
- provider
- $anchorScrollProvider
- $animateProvider
- $compileProvider
- $controllerProvider
- $filterProvider
- $httpProvider
- $interpolateProvider
- $locationProvider
- $logProvider
- $parseProvider
- $rootScopeProvider
- $sceDelegateProvider
- $sceProvider
- service
- $anchorScroll
- $animate
- $cacheFactory
- $compile
- $controller
- $document
- $exceptionHandler
- $filter
- $http
- $httpBackend
- $interpolate
- $interval
- $locale
- $location
- $log
- $parse
- $q
- $rootElement
- $rootScope
- $sce
- $sceDelegate
- $templateCache
- $templateRequest
- $timeout
- $window
- filter
- currency
- date
- filter
- json
- limitTo
- lowercase
- number
- orderBy
- uppercase
- auto
- ngAnimate
- ngAria
- ngCookies
- ngMessages
- ngMock
- ngMockE2E
- ngResource
- ngRoute
- ngSanitize
- ngTouch
ngAria
The ngAria
module provides support for common
ARIA
attributes that convey state or semantic information about the application for users
of assistive technologies, such as screen readers.
Usage
For ngAria to do its magic, simply include the module as a dependency. The directives supported
by ngAria are:
ngModel
, ngDisabled
, ngShow
, ngHide
, ngClick
, ngDblClick
, and ngMessages
.
Below is a more detailed breakdown of the attributes handled by ngAria:
Directive | Supported Attributes |
---|---|
ngModel | aria-checked, aria-valuemin, aria-valuemax, aria-valuenow, aria-invalid, aria-required |
ngDisabled | aria-disabled |
ngShow | aria-hidden |
ngHide | aria-hidden |
ngClick | tabindex, keypress event |
ngDblclick | tabindex |
ngMessages | aria-live |
Find out more information about each directive by reading the ngAria Developer Guide.
Example
Using ngDisabled with ngAria:
<md-checkbox ng-disabled="disabled">
Becomes:
<md-checkbox ng-disabled="disabled" aria-disabled="true">
Disabling Attributes
It's possible to disable individual attributes added by ngAria with the config method. For more details, see the Developer Guide.
Installation
First include angular-aria.js
in your HTML:
<script src="angular.js">
<script src="angular-aria.js">
You can download this file from the following places:
-
Google CDN
e.g.//ajax.googleapis.com/ajax/libs/angularjs/X.Y.Z/angular-aria.js
-
Bower
e.g.bower install angular-aria@X.Y.Z
-
code.angularjs.org
e.g."//code.angularjs.org/X.Y.Z/angular-aria.js"
where X.Y.Z is the AngularJS version you are running.
Then load the module in your application by adding it as a dependent module:
angular.module('app', ['ngAria']);
With that you're ready to get started!
Module Components
Provider
Name | Description |
---|---|
$ariaProvider | Used for configuring the ARIA attributes injected and managed by ngAria. |