forked from mirrors/iceshrimp
[mastodon-client] Correctly render remote mentions of local users
This commit is contained in:
parent
73895e856c
commit
f5c6cba3a6
|
@ -122,11 +122,12 @@ export class MfmHelpers {
|
||||||
|
|
||||||
mention(node) {
|
mention(node) {
|
||||||
const a = doc.createElement("a");
|
const a = doc.createElement("a");
|
||||||
const { username, host, acct } = node.props;
|
const { username, host} = node.props;
|
||||||
const remoteUserInfo = mentionedRemoteUsers.find(
|
const remoteUserInfo = mentionedRemoteUsers.find(
|
||||||
(remoteUser) =>
|
(remoteUser) =>
|
||||||
remoteUser.username === username && remoteUser.host === host,
|
remoteUser.username === username && remoteUser.host === host,
|
||||||
);
|
);
|
||||||
|
const acct = host === config.domain ? `@${username}` : node.props.acct;
|
||||||
a.href = remoteUserInfo
|
a.href = remoteUserInfo
|
||||||
? remoteUserInfo.url
|
? remoteUserInfo.url
|
||||||
? remoteUserInfo.url
|
? remoteUserInfo.url
|
||||||
|
|
Loading…
Reference in a new issue