tweak roomheader layout when editing

pull/21833/head
Matthew Hodgson 2016-01-15 15:23:41 +00:00
parent b8afccd445
commit aefecfc645
2 changed files with 6 additions and 4 deletions

View File

@ -213,7 +213,7 @@ module.exports = React.createClass({
if (this.props.room) { if (this.props.room) {
if (this.props.editing) { if (this.props.editing) {
roomAvatar = ( roomAvatar = (
<div onClick={ this.onAvatarPickerClick }> <div className="mx_RoomHeader_avatarPicker" onClick={ this.onAvatarPickerClick }>
<ChangeAvatar room={this.props.room} showUploadSection={false} width={48} height={48} /> <ChangeAvatar room={this.props.room} showUploadSection={false} width={48} height={48} />
<div className="mx_RoomHeader_avatarPicker_edit"> <div className="mx_RoomHeader_avatarPicker_edit">
<label htmlFor="avatarInput" ref="file_label"> <label htmlFor="avatarInput" ref="file_label">
@ -228,7 +228,9 @@ module.exports = React.createClass({
} }
else { else {
roomAvatar = ( roomAvatar = (
<RoomAvatar room={this.props.room} width="48" height="48" /> <div onClick={this.props.onSettingsClick}>
<RoomAvatar room={this.props.room} width="48" height="48"/>
</div>
); );
} }
} }
@ -279,7 +281,7 @@ module.exports = React.createClass({
} }
return ( return (
<div className="mx_RoomHeader"> <div className={ "mx_RoomHeader " + (this.props.editing ? "mx_RoomHeader_editing" : "") }>
{ header } { header }
</div> </div>
); );

View File

@ -39,7 +39,7 @@ module.exports = React.createClass({
getDefaultProps: function() { getDefaultProps: function() {
return { return {
showUploadSection: true, showUploadSection: true,
className: "mx_Dialog_content", // FIXME - shouldn't be this by default className: "",
width: 80, width: 80,
height: 80, height: 80,
}; };