diff --git a/src/components/views/settings/ChangeAvatar.tsx b/src/components/views/settings/ChangeAvatar.tsx
index 7a3e639876..7126fe8cc3 100644
--- a/src/components/views/settings/ChangeAvatar.tsx
+++ b/src/components/views/settings/ChangeAvatar.tsx
@@ -18,11 +18,12 @@ limitations under the License.
import React from 'react';
import { MatrixEvent, Room } from 'matrix-js-sdk/src';
import { MatrixClientPeg } from "../../../MatrixClientPeg";
-import * as sdk from '../../../index';
import { _t } from '../../../languageHandler';
import Spinner from '../elements/Spinner';
import { replaceableComponent } from "../../../utils/replaceableComponent";
import { mediaFromMxc } from "../../../customisations/Media";
+import RoomAvatar from '../avatars/RoomAvatar';
+import BaseAvatar from '../avatars/BaseAvatar';
interface IProps {
initialAvatarUrl?: string;
@@ -155,7 +156,6 @@ export default class ChangeAvatar extends React.Component
{
// Having just set an avatar we just display that since it will take a little
// time to propagate through to the RoomAvatar.
if (this.props.room && !this.avatarSet) {
- const RoomAvatar = sdk.getComponent('avatars.RoomAvatar');
avatarImg = {
resizeMethod='crop'
/>;
} else {
- const BaseAvatar = sdk.getComponent("avatars.BaseAvatar");
// XXX: FIXME: once we track in the JS what our own displayname is(!) then use it here rather than ?
avatarImg = {
}
// pop up an interactive auth dialog
- const InteractiveAuthDialog = sdk.getComponent("dialogs.InteractiveAuthDialog");
const numDevices = this.state.selectedDevices.length;
const dialogAesthetics = {
diff --git a/src/components/views/settings/DevicesPanelEntry.tsx b/src/components/views/settings/DevicesPanelEntry.tsx
index d44147f591..3762f7be83 100644
--- a/src/components/views/settings/DevicesPanelEntry.tsx
+++ b/src/components/views/settings/DevicesPanelEntry.tsx
@@ -18,12 +18,12 @@ limitations under the License.
import React from 'react';
import { IMyDevice } from 'matrix-js-sdk/src';
-import * as sdk from '../../../index';
import { _t } from '../../../languageHandler';
import { MatrixClientPeg } from '../../../MatrixClientPeg';
import { formatDate } from '../../../DateUtils';
import StyledCheckbox from '../elements/StyledCheckbox';
import { replaceableComponent } from "../../../utils/replaceableComponent";
+import EditableTextContainer from "../elements/EditableTextContainer";
interface IProps {
device?: IMyDevice;
@@ -52,8 +52,6 @@ export default class DevicesPanelEntry extends React.Component {
};
public render(): JSX.Element {
- const EditableTextContainer = sdk.getComponent('elements.EditableTextContainer');
-
const device = this.props.device;
let lastSeen = "";
diff --git a/src/components/views/settings/IntegrationManager.tsx b/src/components/views/settings/IntegrationManager.tsx
index f43fb55004..7b221aceec 100644
--- a/src/components/views/settings/IntegrationManager.tsx
+++ b/src/components/views/settings/IntegrationManager.tsx
@@ -17,12 +17,12 @@ limitations under the License.
*/
import React from 'react';
-import * as sdk from '../../../index';
import { _t } from '../../../languageHandler';
import dis from '../../../dispatcher/dispatcher';
import { Key } from "../../../Keyboard";
import { replaceableComponent } from "../../../utils/replaceableComponent";
import { ActionPayload } from '../../../dispatcher/payloads';
+import Spinner from "../elements/Spinner";
interface IProps {
// false to display an error saying that we couldn't connect to the integration manager
@@ -85,7 +85,6 @@ export default class IntegrationManager extends React.Component
public render(): JSX.Element {
if (this.props.loading) {
- const Spinner = sdk.getComponent("elements.Spinner");
return (
{ _t("Connecting to integration manager...") }
diff --git a/src/components/views/settings/ProfileSettings.tsx b/src/components/views/settings/ProfileSettings.tsx
index 888ff8967b..9bd7179f08 100644
--- a/src/components/views/settings/ProfileSettings.tsx
+++ b/src/components/views/settings/ProfileSettings.tsx
@@ -19,12 +19,13 @@ import { _t } from "../../../languageHandler";
import { MatrixClientPeg } from "../../../MatrixClientPeg";
import Field from "../elements/Field";
import { getHostingLink } from '../../../utils/HostingLink';
-import * as sdk from "../../../index";
import { OwnProfileStore } from "../../../stores/OwnProfileStore";
import Modal from "../../../Modal";
import ErrorDialog from "../dialogs/ErrorDialog";
import { replaceableComponent } from "../../../utils/replaceableComponent";
import { mediaFromMxc } from "../../../customisations/Media";
+import AccessibleButton from '../elements/AccessibleButton';
+import AvatarSetting from './AvatarSetting';
interface IProps {
@@ -174,8 +175,6 @@ export default class ProfileSettings extends React.Component {
;
}
- const AccessibleButton = sdk.getComponent('elements.AccessibleButton');
- const AvatarSetting = sdk.getComponent('settings.AvatarSetting');
return (