You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-05 23:10:41 +03:00
Inline display name into return
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
This commit is contained in:
@@ -118,12 +118,6 @@ export default class SenderProfile extends React.Component<IProps, IState> {
|
|||||||
return null; // emote message must include the name so don't duplicate it
|
return null; // emote message must include the name so don't duplicate it
|
||||||
}
|
}
|
||||||
|
|
||||||
const displayNameElement = (
|
|
||||||
<span className={`mx_SenderProfile_displayName ${colorClass}`}>
|
|
||||||
{ displayName }
|
|
||||||
</span>
|
|
||||||
);
|
|
||||||
|
|
||||||
let mxidElement;
|
let mxidElement;
|
||||||
if (disambiguate) {
|
if (disambiguate) {
|
||||||
mxidElement = (
|
mxidElement = (
|
||||||
@@ -147,7 +141,9 @@ export default class SenderProfile extends React.Component<IProps, IState> {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="mx_SenderProfile mx_SenderProfile_hover" dir="auto" onClick={this.props.onClick}>
|
<div className="mx_SenderProfile mx_SenderProfile_hover" dir="auto" onClick={this.props.onClick}>
|
||||||
{ displayNameElement }
|
<span className={`mx_SenderProfile_displayName ${colorClass}`}>
|
||||||
|
{ displayName }
|
||||||
|
</span>
|
||||||
{ mxidElement }
|
{ mxidElement }
|
||||||
{ flair }
|
{ flair }
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user