This repository was archived by the owner on Sep 5, 2024. It is now read-only.
This repository was archived by the owner on Sep 5, 2024. It is now read-only.
Allow developers to disable attributes injected by ngAria #600
Closed
Description
One nice feature of ngAria is that developers can disable specific attributes that conflict with their own implementation, for example, if they already manage tabindex
. Because of our mix of ngAria and custom accessibility support, opting out of attributes managed both by us and by ngAria is not possible. For example, see these two code snippets:
var app = angular.module( 'app', ['ngAnimate','ngMaterial'],
function config($ariaProvider) {
$ariaProvider.config({
tabindex: false,
ariaInvalid: false
});
});
<md-radio-group ng-model="data.group1">
<md-radio-button value="Apple" aria-label="Apple">Apple</md-radio-button>
<md-radio-button value="Banana" aria-label="Banana">Banana</md-radio-button>
<md-radio-button value="Mango" aria-label="Mango">Mango</md-radio-button>
</md-radio-group>
tabindex
is added to <md-radio-group>
by Angular Material so only aria-invalid
is suppressed, not tabindex
. ngAria leaves the existing tabindex intact, as it should.
As much as it seems like a bad idea to allow people to disable accessibility support for attributes, should we create a mechanism to support custom disabling of attributes in this way, since it is supported by ngAria?
Related: #583 (bug)