experiments in dharma

This commit is contained in:
Matthew Hodgson 2018-05-25 03:17:29 +01:00
parent 693ccf69c7
commit 3bf28a08ec
30 changed files with 454 additions and 72 deletions

View file

@ -146,7 +146,7 @@ export default React.createClass({
const RoomTooltip = sdk.getComponent('rooms.RoomTooltip');
const profile = this.state.profile || {};
const name = profile.name || this.props.tag;
const avatarHeight = 35;
const avatarHeight = 40;
const httpUrl = profile.avatarUrl ? this.context.matrixClient.mxcUrlToHttp(
profile.avatarUrl, avatarHeight, avatarHeight, "crop",

View file

@ -248,6 +248,10 @@ module.exports = React.createClass({
/>);
});
if (apps.length == 0) {
return <div></div>;
}
let addWidget;
if (this.props.showApps &&
this._canUserModify()

View file

@ -302,11 +302,12 @@ module.exports = React.createClass({
}
let roomAvatar = null;
const avatarSize = 28;
if (canSetRoomAvatar) {
roomAvatar = (
<div className="mx_RoomHeader_avatarPicker">
<div onClick={this.onAvatarPickerClick}>
<ChangeAvatar ref="changeAvatar" room={this.props.room} showUploadSection={false} width={48} height={48} />
<ChangeAvatar ref="changeAvatar" room={this.props.room} showUploadSection={false} width={avatarSize} height={avatarSize} />
</div>
<div className="mx_RoomHeader_avatarPicker_edit">
<label htmlFor="avatarInput" ref="file_label">
@ -327,7 +328,7 @@ module.exports = React.createClass({
);
} else if (this.props.room || (this.props.oobData && this.props.oobData.name)) {
roomAvatar = (
<RoomAvatar room={this.props.room} width={48} height={48} oobData={this.props.oobData}
<RoomAvatar room={this.props.room} width={avatarSize} height={avatarSize} oobData={this.props.oobData}
viewAvatarOnClick={true} />
);
}

View file

@ -320,7 +320,7 @@ module.exports = React.createClass({
return <AccessibleButton className={classes} tabIndex="0" onClick={this.onClick} onMouseEnter={this.onMouseEnter} onMouseLeave={this.onMouseLeave}>
<div className={avatarClasses}>
<div className="mx_RoomTile_avatar_container">
<RoomAvatar room={this.props.room} width={24} height={24} />
<RoomAvatar room={this.props.room} width={32} height={32} />
{ directMessageIndicator }
</div>
</div>