Skip to content

Commit a240c9c

Browse files
crisbetoandrewseguin
authored andcommitted
fix(list): set aria attributes to md-divider (#4925)
Sets the appropriate role and `aria-orientation` on the `md-divider` element.
1 parent 1055720 commit a240c9c

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/lib/list/list.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,20 @@ import {
1414
import {coerceBooleanProperty, MdLine, MdLineSetter} from '../core';
1515

1616
@Directive({
17-
selector: 'md-divider, mat-divider'
17+
selector: 'md-divider, mat-divider',
18+
host: {
19+
'role': 'separator',
20+
'aria-orientation': 'horizontal'
21+
}
1822
})
1923
export class MdListDivider {}
2024

2125
@Component({
2226
moduleId: module.id,
2327
selector: 'md-list, mat-list, md-nav-list, mat-nav-list',
2428
host: {
25-
'role': 'list'},
29+
'role': 'list'
30+
},
2631
template: '<ng-content></ng-content>',
2732
styleUrls: ['list.css'],
2833
encapsulation: ViewEncapsulation.None

0 commit comments

Comments
 (0)