File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
src/material-experimental/mdc-chips Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -257,6 +257,12 @@ export class MatChip extends _MatChipMixinBase implements AfterContentInit, Afte
257257 } ,
258258 hasLeadingIcon : ( ) => { return ! ! this . leadingIcon ; } ,
259259 setAttr : ( name : string , value : string ) => {
260+ // MDC is currently using this method to set aria-checked on choice and filter chips,
261+ // which in the MDC templates have role="checkbox" and role="radio" respectively.
262+ // We have role="option" on those chips instead, so we do not want aria-checked.
263+ if ( name === 'aria-checked' ) {
264+ return ;
265+ }
260266 this . _elementRef . nativeElement . setAttribute ( name , value ) ;
261267 } ,
262268 // The 2 functions below are used by the MDC ripple, which we aren't using,
You can’t perform that action at this time.
0 commit comments