Fix avatars vanishing on hover

Turns out the z-index was to make the avatar appear above the
EventTile_line even though it comes before in the DOM (it's
absolutely positioned to overlap with it). Instead, just put
it afterwards in the DOM.
pull/21833/head
David Baker 2018-07-12 17:48:49 +01:00
parent f0dbd161b3
commit 5a5e967262
1 changed files with 6 additions and 1 deletions

View File

@ -695,7 +695,6 @@ module.exports = withMatrixClient(React.createClass({
<div className="mx_EventTile_msgOption"> <div className="mx_EventTile_msgOption">
{ readAvatars } { readAvatars }
</div> </div>
{ avatar }
{ sender } { sender }
<div className="mx_EventTile_line"> <div className="mx_EventTile_line">
<a href={permalink} onClick={this.onPermalinkClicked}> <a href={permalink} onClick={this.onPermalinkClicked}>
@ -712,6 +711,12 @@ module.exports = withMatrixClient(React.createClass({
{ keyRequestInfo } { keyRequestInfo }
{ editButton } { editButton }
</div> </div>
{
// The avatar goes after the event tile as it's absolutly positioned to be over the
// event tile line, so needs to be later in the DOM so it appears on top (this avoids
// the need for further z-indexing chaos)
}
{ avatar }
</div> </div>
); );
} }