From 656a815991dbdb86fcb98ae2cc28903e9abf9b6e Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Tue, 1 Sep 2020 09:07:46 +0100 Subject: [PATCH] delint some more --- .../dialogs/CreateCommunityPrototypeDialog.tsx | 6 ++---- src/components/views/elements/EventTilePreview.tsx | 14 +++++++------- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/src/components/views/dialogs/CreateCommunityPrototypeDialog.tsx b/src/components/views/dialogs/CreateCommunityPrototypeDialog.tsx index dbfc208583..1d9d92b9c9 100644 --- a/src/components/views/dialogs/CreateCommunityPrototypeDialog.tsx +++ b/src/components/views/dialogs/CreateCommunityPrototypeDialog.tsx @@ -163,11 +163,9 @@ export default class CreateCommunityPrototypeDialog extends React.PureComponent< ); if (this.state.error) { + const classes = "mx_CreateCommunityPrototypeDialog_subtext mx_CreateCommunityPrototypeDialog_subtext_error"; helpText = ( - + {this.state.error} ); diff --git a/src/components/views/elements/EventTilePreview.tsx b/src/components/views/elements/EventTilePreview.tsx index 98f6850e6b..61e5f5381d 100644 --- a/src/components/views/elements/EventTilePreview.tsx +++ b/src/components/views/elements/EventTilePreview.tsx @@ -45,6 +45,7 @@ interface IState { displayname: string; avatar_url: string; } +/* eslint-enable camelcase */ const AVATAR_SIZE = 32; @@ -64,18 +65,18 @@ export default class EventTilePreview extends React.Component { const client = MatrixClientPeg.get(); const userId = client.getUserId(); const profileInfo = await client.getProfileInfo(userId); - const avatar_url = Avatar.avatarUrlForUser( + const avatarUrl = Avatar.avatarUrlForUser( {avatarUrl: profileInfo.avatar_url}, AVATAR_SIZE, AVATAR_SIZE, "crop"); this.setState({ userId, displayname: profileInfo.displayname, - avatar_url, + avatar_url: avatarUrl, }); } - private fakeEvent({userId, displayname, avatar_url}: IState) { + private fakeEvent({userId, displayname, avatar_url: avatarUrl}: IState) { // Fake it till we make it const event = new MatrixEvent(JSON.parse(`{ "type": "m.room.message", @@ -85,12 +86,12 @@ export default class EventTilePreview extends React.Component { "msgtype": "m.text", "body": "${this.props.message}", "displayname": "${displayname}", - "avatar_url": "${avatar_url}" + "avatar_url": "${avatarUrl}" }, "msgtype": "m.text", "body": "${this.props.message}", "displayname": "${displayname}", - "avatar_url": "${avatar_url}" + "avatar_url": "${avatarUrl}" }, "unsigned": { "age": 97 @@ -104,7 +105,7 @@ export default class EventTilePreview extends React.Component { name: displayname, userId: userId, getAvatarUrl: (..._) => { - return avatar_url; + return avatarUrl; }, }; @@ -124,4 +125,3 @@ export default class EventTilePreview extends React.Component { ; } } -/* eslint-enable camelcase */