You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-07 10:46:24 +03:00
Add comments regarding tab-index=-1
This commit is contained in:
@@ -57,6 +57,7 @@ export default class DateSeparator extends React.Component {
|
|||||||
|
|
||||||
render() {
|
render() {
|
||||||
// ARIA treats <hr/>s as separators, here we abuse them slightly so manually treat this entire thing as one
|
// 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}>
|
||||||
<hr role="none" />
|
<hr role="none" />
|
||||||
<div>{ this.getLabel() }</div>
|
<div>{ this.getLabel() }</div>
|
||||||
|
|||||||
@@ -787,6 +787,7 @@ module.exports = createReactClass({
|
|||||||
this.props.permalinkCreator,
|
this.props.permalinkCreator,
|
||||||
'replyThread',
|
'replyThread',
|
||||||
);
|
);
|
||||||
|
// tab-index=-1 to allow it to be focusable but do not add tab stop for it, primarily for screen readers
|
||||||
return (
|
return (
|
||||||
<div className={classes} tabIndex={-1}>
|
<div className={classes} tabIndex={-1}>
|
||||||
<div className="mx_EventTile_msgOption">
|
<div className="mx_EventTile_msgOption">
|
||||||
|
|||||||
Reference in New Issue
Block a user