From 8540e05da0d5d7337094ef9a2b1da66c02dea24a Mon Sep 17 00:00:00 2001 From: Chris Bubernak Date: Wed, 17 Feb 2021 09:23:53 -0800 Subject: [PATCH] add aria-atomic --- src/material-experimental/mdc-form-field/directives/error.ts | 1 + src/material/form-field/error.ts | 1 + 2 files changed, 2 insertions(+) diff --git a/src/material-experimental/mdc-form-field/directives/error.ts b/src/material-experimental/mdc-form-field/directives/error.ts index 0c466cb60b31..e00b1a7e339a 100644 --- a/src/material-experimental/mdc-form-field/directives/error.ts +++ b/src/material-experimental/mdc-form-field/directives/error.ts @@ -22,6 +22,7 @@ export const MAT_ERROR = new InjectionToken('MatError'); selector: 'mat-error', host: { 'class': 'mat-mdc-form-field-error mat-mdc-form-field-bottom-align', + 'aria-atomic': 'true', '[attr.aria-live]': 'ariaLive', '[id]': 'id', }, diff --git a/src/material/form-field/error.ts b/src/material/form-field/error.ts index 344fda9be0b9..3c3ce1e8cae4 100644 --- a/src/material/form-field/error.ts +++ b/src/material/form-field/error.ts @@ -23,6 +23,7 @@ export const MAT_ERROR = new InjectionToken('MatError'); host: { 'class': 'mat-error', '[attr.id]': 'id', + 'aria-atomic': 'true', '[attr.aria-live]': 'ariaLive', }, providers: [{provide: MAT_ERROR, useExisting: MatError}],