Step 3.2: Stop using getComponent
in code
This commit is contained in:
parent
d977865b8e
commit
b667ef9f18
18 changed files with 54 additions and 93 deletions
|
@ -17,11 +17,11 @@ limitations under the License.
|
|||
import React, { createRef } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
|
||||
import * as sdk from '../../../index';
|
||||
import { _t } from '../../../languageHandler';
|
||||
import { linkifyElement } from '../../../HtmlUtils';
|
||||
import { mediaFromMxc } from "../../../customisations/Media";
|
||||
import { getDisplayAliasForAliasSet } from '../../../Rooms';
|
||||
import BaseAvatar from "../avatars/BaseAvatar";
|
||||
|
||||
export function getDisplayAliasForRoom(room) {
|
||||
return getDisplayAliasForAliasSet(room.canonicalAlias, room.aliases);
|
||||
|
@ -82,8 +82,6 @@ export default class RoomDetailRow extends React.Component {
|
|||
};
|
||||
|
||||
render() {
|
||||
const BaseAvatar = sdk.getComponent('avatars.BaseAvatar');
|
||||
|
||||
const room = this.props.room;
|
||||
const name = room.name || getDisplayAliasForRoom(room) || _t('Unnamed room');
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue