encore du lipstick

This commit is contained in:
Matthew Hodgson 2015-07-18 00:48:22 +01:00
parent b685e784f1
commit 4ded74765a
19 changed files with 76 additions and 50 deletions

View file

@ -57,13 +57,21 @@ module.exports = React.createClass({
mx_MessageTile_continuation: this.props.continuation,
});
var timestamp = this.props.last ? <MessageTimestamp ts={this.props.mxEvent.getTs()} /> : null;
return (
<div className={classes}>
var avatar;
var sender;
if (!this.props.continuation) {
avatar = (
<div className="mx_MessageTile_avatar">
<img src={ this.props.mxEvent.sender ? MatrixClientPeg.get().getAvatarUrlForMember(this.props.mxEvent.sender, 40, 40, "crop") : null } width="40" height="40" alt=""/>
</div>
);
sender = <SenderProfile mxEvent={this.props.mxEvent} />;
}
return (
<div className={classes}>
{ avatar }
{ timestamp }
<SenderProfile mxEvent={this.props.mxEvent} />
{ sender }
<TileType mxEvent={this.props.mxEvent} />
</div>
);