Fix Breadcrumbs2 ending up with 2 tabIndexes on Firefox due to explicit css overflow scroll

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
Michael Telatynski 2020-07-18 12:19:03 +01:00
parent 58532f2ac4
commit fabed26b09
3 changed files with 11 additions and 7 deletions

View file

@ -43,6 +43,7 @@ export default class AutoHideScrollbar extends React.Component {
className={["mx_AutoHideScrollbar", this.props.className].join(" ")} className={["mx_AutoHideScrollbar", this.props.className].join(" ")}
onScroll={this.props.onScroll} onScroll={this.props.onScroll}
onWheel={this.props.onWheel} onWheel={this.props.onWheel}
tabIndex={this.props.tabIndex}
> >
{ this.props.children } { this.props.children }
</div>); </div>);

View file

@ -327,6 +327,9 @@ export default class LeftPanel2 extends React.Component<IProps, IState> {
<IndicatorScrollbar <IndicatorScrollbar
className="mx_LeftPanel2_breadcrumbsContainer mx_AutoHideScrollbar" className="mx_LeftPanel2_breadcrumbsContainer mx_AutoHideScrollbar"
verticalScrollsHorizontally={true} verticalScrollsHorizontally={true}
// Firefox sometimes makes this element focusable due to
// overflow:scroll;, so force it out of tab order.
tabIndex={-1}
> >
<RoomBreadcrumbs2 /> <RoomBreadcrumbs2 />
</IndicatorScrollbar> </IndicatorScrollbar>