Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Make message separator more accessible. (#7056)
Browse files Browse the repository at this point in the history
  • Loading branch information
ndarilek authored Oct 29, 2021
1 parent 98edc46 commit ea54ea8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/views/messages/DateSeparator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ export default class DateSeparator extends React.Component<IProps> {
render() {
// ARIA treats <hr/>s as separators, here we abuse them slightly so manually treat this entire thing as one
// tab-index=-1 to allow it to be focusable but do not add tab stop for it, primarily for screen readers
return <h2 className="mx_DateSeparator" role="separator" tabIndex={-1}>
return <h2 className="mx_DateSeparator" role="separator" tabIndex={-1} aria-label={this.getLabel()}>
<hr role="none" />
<div>{ this.getLabel() }</div>
<div aria-hidden="true">{ this.getLabel() }</div>
<hr role="none" />
</h2>;
}
Expand Down

0 comments on commit ea54ea8

Please sign in to comment.