Minor styling and avatar bug fixing
This commit is contained in:
parent
9a524c49b1
commit
ea1d6a0146
3 changed files with 7 additions and 2 deletions
|
@ -17,3 +17,7 @@ limitations under the License.
|
|||
.mx_GeneralRoomSettingsTab_profileSection {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.mx_GeneralRoomSettingsTab .mx_AliasSettings .mx_Field select {
|
||||
width: 100%;
|
||||
}
|
||||
|
|
|
@ -279,7 +279,7 @@ module.exports = React.createClass({
|
|||
}
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div className='mx_AliasSettings'>
|
||||
{canonical_alias_section}
|
||||
<EditableItemList
|
||||
className={"mx_RoomSettings_localAliases"}
|
||||
|
|
|
@ -34,7 +34,8 @@ export default class RoomProfileSettings extends React.Component {
|
|||
const client = MatrixClientPeg.get();
|
||||
const room = client.getRoom(props.roomId);
|
||||
if (!room) throw new Error("Expected a room for ID: ", props.roomId);
|
||||
let avatarUrl = room.avatarUrl;
|
||||
const avatarEvent = room.currentState.getStateEvents("m.room.avatar", "");
|
||||
let avatarUrl = avatarEvent && avatarEvent.getContent() ? avatarEvent.getContent()["url"] : null;
|
||||
if (avatarUrl) avatarUrl = client.mxcUrlToHttp(avatarUrl, 96, 96, 'crop', false);
|
||||
const topicEvent = room.currentState.getStateEvents("m.room.topic", "");
|
||||
const topic = topicEvent && topicEvent.getContent() ? topicEvent.getContent()['topic'] : null;
|
||||
|
|
Loading…
Reference in a new issue