From 8166cfc7042077f09f86b99becdd983dd40c5f9b Mon Sep 17 00:00:00 2001 From: Jullierme Barros Date: Mon, 9 Sep 2024 18:03:24 -0300 Subject: [PATCH] feat(material/checkbox): add new aria properties to MatCheckbox Added three new aria properties to MatCheckbox: `aria-expanded`: Indicates whether the checkbox controls the visibility of another element. This should be a boolean value (true or false). `aria-controls`: Specifies the ID of the element that the checkbox controls. `aria-owns`: Specifies the ID of the element that the checkbox visually owns. These attributes will be added to the generated checkbox element if they are specified and won't be present in the HTML if not provided. Also added a small paragraph at the end of the checkbox.md file. Fixes #28761 --- src/material/checkbox/checkbox.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/material/checkbox/checkbox.html b/src/material/checkbox/checkbox.html index d4f2aa21c160..759f09f64bed 100644 --- a/src/material/checkbox/checkbox.html +++ b/src/material/checkbox/checkbox.html @@ -10,9 +10,9 @@ [attr.aria-labelledby]="ariaLabelledby" [attr.aria-describedby]="ariaDescribedby" [attr.aria-checked]="indeterminate ? 'mixed' : null" + [attr.aria-controls]="ariaControls" [attr.aria-disabled]="disabled && disabledInteractive ? true : null" [attr.aria-expanded]="ariaExpanded" - [attr.aria-controls]="ariaControls" [attr.aria-owns]="ariaOwns" [attr.name]="name" [attr.value]="value"