mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-17 14:05:04 +08:00
Misc code cleanup
This commit is contained in:
parent
9b64dd0cd7
commit
87ca3069bb
@ -88,10 +88,10 @@ export default class IndicatorScrollbar extends React.Component {
|
|||||||
if (this.props.trackHorizontalOverflow) {
|
if (this.props.trackHorizontalOverflow) {
|
||||||
this.setState({
|
this.setState({
|
||||||
// Offset from absolute position of the container
|
// Offset from absolute position of the container
|
||||||
leftIndicatorOffset: hasLeftOverflow ? `${this._scrollElement.scrollLeft}px` : 0,
|
leftIndicatorOffset: hasLeftOverflow ? `${this._scrollElement.scrollLeft}px` : '0',
|
||||||
|
|
||||||
// Negative because we're coming from the right
|
// Negative because we're coming from the right
|
||||||
rightIndicatorOffset: hasRightOverflow ? `-${this._scrollElement.scrollLeft}px` : 0,
|
rightIndicatorOffset: hasRightOverflow ? `-${this._scrollElement.scrollLeft}px` : '0',
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -134,8 +134,7 @@ export default class RoomBreadcrumbs extends React.Component {
|
|||||||
);
|
);
|
||||||
});
|
});
|
||||||
return (
|
return (
|
||||||
<IndicatorScrollbar ref="scroller" className="mx_RoomBreadcrumbs" onScroll={ this._onScroll }
|
<IndicatorScrollbar ref="scroller" className="mx_RoomBreadcrumbs" trackHorizontalOverflow={true}>
|
||||||
trackHorizontalOverflow={true}>
|
|
||||||
{ avatars }
|
{ avatars }
|
||||||
</IndicatorScrollbar>
|
</IndicatorScrollbar>
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user